window.phoenix&&(window.phoenix.buildInfo||(window.phoenix.buildInfo=[]),-1===window.phoenix.buildInfo.findIndex((t=>"Phoenix-experience"===t.MFE))&&window.phoenix.buildInfo.push({MFE:"Phoenix-experience",VERSION:"rc-phoenix-experience-1.1.26105.1370789671-5a319f99-4-gb151444",LASTCOMMITDATETIME:"2024-07-12T10:57:26+00:00"})) /*! * * ============= BUILD INFO ============= * MFE: Phoenix-experience * chunkName: clientlib-experience-components/index * VERSION: rc-phoenix-experience-1.1.26105.1370789671-5a319f99-4-gb151444 * BRANCH: HEAD * COMMITHASH: b15144446b0aeb869603529fd56baec1576b10c9 * LASTCOMMITDATETIME: 2024-07-12T10:57:26+00:00 * ============= If you're reading this, why not come work with us? https://www.t-mobile.com/careers ============= */,function(){var t={2543:function(t,e,n){var i; /** * @license * Lodash * Copyright OpenJS Foundation and other contributors * Released under MIT license * Based on Underscore.js 1.8.3 * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */t=n.nmd(t),function(){var r,a="Expected a function",o="__lodash_hash_undefined__",s="__lodash_placeholder__",u=16,l=32,c=64,d=128,h=256,p=1/0,f=9007199254740991,m=NaN,y=4294967295,b=[["ary",d],["bind",1],["bindKey",2],["curry",8],["curryRight",u],["flip",512],["partial",l],["partialRight",c],["rearg",h]],g="[object Arguments]",v="[object Array]",w="[object Boolean]",_="[object Date]",A="[object Error]",E="[object Function]",x="[object GeneratorFunction]",T="[object Map]",I="[object Number]",C="[object Object]",S="[object Promise]",D="[object RegExp]",L="[object Set]",F="[object String]",M="[object Symbol]",O="[object WeakMap]",N="[object ArrayBuffer]",k="[object DataView]",P="[object Float32Array]",V="[object Float64Array]",R="[object Int8Array]",$="[object Int16Array]",B="[object Int32Array]",q="[object Uint8Array]",j="[object Uint8ClampedArray]",U="[object Uint16Array]",H="[object Uint32Array]",W=/\b__p \+= '';/g,z=/\b(__p \+=) '' \+/g,G=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Y=/&(?:amp|lt|gt|quot|#39);/g,K=/[&<>"']/g,X=RegExp(Y.source),J=RegExp(K.source),Z=/<%-([\s\S]+?)%>/g,Q=/<%([\s\S]+?)%>/g,tt=/<%=([\s\S]+?)%>/g,et=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,nt=/^\w*$/,it=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,rt=/[\\^$.*+?()[\]{}|]/g,at=RegExp(rt.source),ot=/^\s+/,st=/\s/,ut=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,lt=/\{\n\/\* \[wrapped with (.+)\] \*/,ct=/,? & /,dt=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,ht=/[()=,{}\[\]\/\s]/,pt=/\\(\\)?/g,ft=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,mt=/\w*$/,yt=/^[-+]0x[0-9a-f]+$/i,bt=/^0b[01]+$/i,gt=/^\[object .+?Constructor\]$/,vt=/^0o[0-7]+$/i,wt=/^(?:0|[1-9]\d*)$/,_t=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,At=/($^)/,Et=/['\n\r\u2028\u2029\\]/g,xt="\\ud800-\\udfff",Tt="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",It="\\u2700-\\u27bf",Ct="a-z\\xdf-\\xf6\\xf8-\\xff",St="A-Z\\xc0-\\xd6\\xd8-\\xde",Dt="\\ufe0e\\ufe0f",Lt="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Ft="['’]",Mt="["+xt+"]",Ot="["+Lt+"]",Nt="["+Tt+"]",kt="\\d+",Pt="["+It+"]",Vt="["+Ct+"]",Rt="[^"+xt+Lt+kt+It+Ct+St+"]",$t="\\ud83c[\\udffb-\\udfff]",Bt="[^"+xt+"]",qt="(?:\\ud83c[\\udde6-\\uddff]){2}",jt="[\\ud800-\\udbff][\\udc00-\\udfff]",Ut="["+St+"]",Ht="\\u200d",Wt="(?:"+Vt+"|"+Rt+")",zt="(?:"+Ut+"|"+Rt+")",Gt="(?:['’](?:d|ll|m|re|s|t|ve))?",Yt="(?:['’](?:D|LL|M|RE|S|T|VE))?",Kt="(?:"+Nt+"|"+$t+")"+"?",Xt="["+Dt+"]?",Jt=Xt+Kt+("(?:"+Ht+"(?:"+[Bt,qt,jt].join("|")+")"+Xt+Kt+")*"),Zt="(?:"+[Pt,qt,jt].join("|")+")"+Jt,Qt="(?:"+[Bt+Nt+"?",Nt,qt,jt,Mt].join("|")+")",te=RegExp(Ft,"g"),ee=RegExp(Nt,"g"),ne=RegExp($t+"(?="+$t+")|"+Qt+Jt,"g"),ie=RegExp([Ut+"?"+Vt+"+"+Gt+"(?="+[Ot,Ut,"$"].join("|")+")",zt+"+"+Yt+"(?="+[Ot,Ut+Wt,"$"].join("|")+")",Ut+"?"+Wt+"+"+Gt,Ut+"+"+Yt,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",kt,Zt].join("|"),"g"),re=RegExp("["+Ht+xt+Tt+Dt+"]"),ae=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,oe=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],se=-1,ue={};ue[P]=ue[V]=ue[R]=ue[$]=ue[B]=ue[q]=ue[j]=ue[U]=ue[H]=!0,ue[g]=ue[v]=ue[N]=ue[w]=ue[k]=ue[_]=ue[A]=ue[E]=ue[T]=ue[I]=ue[C]=ue[D]=ue[L]=ue[F]=ue[O]=!1;var le={};le[g]=le[v]=le[N]=le[k]=le[w]=le[_]=le[P]=le[V]=le[R]=le[$]=le[B]=le[T]=le[I]=le[C]=le[D]=le[L]=le[F]=le[M]=le[q]=le[j]=le[U]=le[H]=!0,le[A]=le[E]=le[O]=!1;var ce={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},de=parseFloat,he=parseInt,pe="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g,fe="object"==typeof self&&self&&self.Object===Object&&self,me=pe||fe||Function("return this")(),ye=e&&!e.nodeType&&e,be=ye&&t&&!t.nodeType&&t,ge=be&&be.exports===ye,ve=ge&&pe.process,we=function(){try{var t=be&&be.require&&be.require("util").types;return t||ve&&ve.binding&&ve.binding("util")}catch(t){}}(),_e=we&&we.isArrayBuffer,Ae=we&&we.isDate,Ee=we&&we.isMap,xe=we&&we.isRegExp,Te=we&&we.isSet,Ie=we&&we.isTypedArray;function Ce(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}function Se(t,e,n,i){for(var r=-1,a=null==t?0:t.length;++r-1}function Ne(t,e,n){for(var i=-1,r=null==t?0:t.length;++i-1;);return n}function rn(t,e){for(var n=t.length;n--&&Ue(e,t[n],0)>-1;);return n}var an=Ye({"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"}),on=Ye({"&":"&","<":"<",">":">",'"':""","'":"'"});function sn(t){return"\\"+ce[t]}function un(t){return re.test(t)}function ln(t){var e=-1,n=Array(t.size);return t.forEach((function(t,i){n[++e]=[i,t]})),n}function cn(t,e){return function(n){return t(e(n))}}function dn(t,e){for(var n=-1,i=t.length,r=0,a=[];++n",""":'"',"'":"'"});var gn=function t(e){var n,i=(e=null==e?me:gn.defaults(me.Object(),e,gn.pick(me,oe))).Array,st=e.Date,xt=e.Error,Tt=e.Function,It=e.Math,Ct=e.Object,St=e.RegExp,Dt=e.String,Lt=e.TypeError,Ft=i.prototype,Mt=Tt.prototype,Ot=Ct.prototype,Nt=e["__core-js_shared__"],kt=Mt.toString,Pt=Ot.hasOwnProperty,Vt=0,Rt=(n=/[^.]+$/.exec(Nt&&Nt.keys&&Nt.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"",$t=Ot.toString,Bt=kt.call(Ct),qt=me._,jt=St("^"+kt.call(Pt).replace(rt,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ut=ge?e.Buffer:r,Ht=e.Symbol,Wt=e.Uint8Array,zt=Ut?Ut.allocUnsafe:r,Gt=cn(Ct.getPrototypeOf,Ct),Yt=Ct.create,Kt=Ot.propertyIsEnumerable,Xt=Ft.splice,Jt=Ht?Ht.isConcatSpreadable:r,Zt=Ht?Ht.iterator:r,Qt=Ht?Ht.toStringTag:r,ne=function(){try{var t=ha(Ct,"defineProperty");return t({},"",{}),t}catch(t){}}(),re=e.clearTimeout!==me.clearTimeout&&e.clearTimeout,ce=st&&st.now!==me.Date.now&&st.now,pe=e.setTimeout!==me.setTimeout&&e.setTimeout,fe=It.ceil,ye=It.floor,be=Ct.getOwnPropertySymbols,ve=Ut?Ut.isBuffer:r,we=e.isFinite,Be=Ft.join,Ye=cn(Ct.keys,Ct),vn=It.max,wn=It.min,_n=st.now,An=e.parseInt,En=It.random,xn=Ft.reverse,Tn=ha(e,"DataView"),In=ha(e,"Map"),Cn=ha(e,"Promise"),Sn=ha(e,"Set"),Dn=ha(e,"WeakMap"),Ln=ha(Ct,"create"),Fn=Dn&&new Dn,Mn={},On=Ra(Tn),Nn=Ra(In),kn=Ra(Cn),Pn=Ra(Sn),Vn=Ra(Dn),Rn=Ht?Ht.prototype:r,$n=Rn?Rn.valueOf:r,Bn=Rn?Rn.toString:r;function qn(t){if(ns(t)&&!Wo(t)&&!(t instanceof Wn)){if(t instanceof Hn)return t;if(Pt.call(t,"__wrapped__"))return $a(t)}return new Hn(t)}var jn=function(){function t(){}return function(e){if(!es(e))return{};if(Yt)return Yt(e);t.prototype=e;var n=new t;return t.prototype=r,n}}();function Un(){}function Hn(t,e){this.__wrapped__=t,this.__actions__=[],this.__chain__=!!e,this.__index__=0,this.__values__=r}function Wn(t){this.__wrapped__=t,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=y,this.__views__=[]}function zn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e=e?t:e)),t}function li(t,e,n,i,a,o){var s,u=1&e,l=2&e,c=4&e;if(n&&(s=a?n(t,i,a,o):n(t)),s!==r)return s;if(!es(t))return t;var d=Wo(t);if(d){if(s=function(t){var e=t.length,n=new t.constructor(e);e&&"string"==typeof t[0]&&Pt.call(t,"index")&&(n.index=t.index,n.input=t.input);return n}(t),!u)return Lr(t,s)}else{var h=ma(t),p=h==E||h==x;if(Ko(t))return xr(t,u);if(h==C||h==g||p&&!a){if(s=l||p?{}:ba(t),!u)return l?function(t,e){return Fr(t,fa(t),e)}(t,function(t,e){return t&&Fr(e,Os(e),t)}(s,t)):function(t,e){return Fr(t,pa(t),e)}(t,ai(s,t))}else{if(!le[h])return a?t:{};s=function(t,e,n){var i=t.constructor;switch(e){case N:return Tr(t);case w:case _:return new i(+t);case k:return function(t,e){var n=e?Tr(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}(t,n);case P:case V:case R:case $:case B:case q:case j:case U:case H:return Ir(t,n);case T:return new i;case I:case F:return new i(t);case D:return function(t){var e=new t.constructor(t.source,mt.exec(t));return e.lastIndex=t.lastIndex,e}(t);case L:return new i;case M:return r=t,$n?Ct($n.call(r)):{}}var r}(t,h,u)}}o||(o=new Xn);var f=o.get(t);if(f)return f;o.set(t,s),ss(t)?t.forEach((function(i){s.add(li(i,e,n,i,t,o))})):is(t)&&t.forEach((function(i,r){s.set(r,li(i,e,n,r,t,o))}));var m=d?r:(c?l?aa:ra:l?Os:Ms)(t);return De(m||t,(function(i,r){m&&(i=t[r=i]),ni(s,r,li(i,e,n,r,t,o))})),s}function ci(t,e,n){var i=n.length;if(null==t)return!i;for(t=Ct(t);i--;){var a=n[i],o=e[a],s=t[a];if(s===r&&!(a in t)||!o(s))return!1}return!0}function di(t,e,n){if("function"!=typeof t)throw new Lt(a);return Fa((function(){t.apply(r,n)}),e)}function hi(t,e,n,i){var r=-1,a=Oe,o=!0,s=t.length,u=[],l=e.length;if(!s)return u;n&&(e=ke(e,Qe(n))),i?(a=Ne,o=!1):e.length>=200&&(a=en,o=!1,e=new Kn(e));t:for(;++r-1},Gn.prototype.set=function(t,e){var n=this.__data__,i=ii(n,t);return i<0?(++this.size,n.push([t,e])):n[i][1]=e,this},Yn.prototype.clear=function(){this.size=0,this.__data__={hash:new zn,map:new(In||Gn),string:new zn}},Yn.prototype.delete=function(t){var e=ca(this,t).delete(t);return this.size-=e?1:0,e},Yn.prototype.get=function(t){return ca(this,t).get(t)},Yn.prototype.has=function(t){return ca(this,t).has(t)},Yn.prototype.set=function(t,e){var n=ca(this,t),i=n.size;return n.set(t,e),this.size+=n.size==i?0:1,this},Kn.prototype.add=Kn.prototype.push=function(t){return this.__data__.set(t,o),this},Kn.prototype.has=function(t){return this.__data__.has(t)},Xn.prototype.clear=function(){this.__data__=new Gn,this.size=0},Xn.prototype.delete=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n},Xn.prototype.get=function(t){return this.__data__.get(t)},Xn.prototype.has=function(t){return this.__data__.has(t)},Xn.prototype.set=function(t,e){var n=this.__data__;if(n instanceof Gn){var i=n.__data__;if(!In||i.length<199)return i.push([t,e]),this.size=++n.size,this;n=this.__data__=new Yn(i)}return n.set(t,e),this.size=n.size,this};var pi=Nr(_i),fi=Nr(Ai,!0);function mi(t,e){var n=!0;return pi(t,(function(t,i,r){return n=!!e(t,i,r)})),n}function yi(t,e,n){for(var i=-1,a=t.length;++i0&&n(s)?e>1?gi(s,e-1,n,i,r):Pe(r,s):i||(r[r.length]=s)}return r}var vi=kr(),wi=kr(!0);function _i(t,e){return t&&vi(t,e,Ms)}function Ai(t,e){return t&&wi(t,e,Ms)}function Ei(t,e){return Me(e,(function(e){return Zo(t[e])}))}function xi(t,e){for(var n=0,i=(e=wr(e,t)).length;null!=t&&ne}function Si(t,e){return null!=t&&Pt.call(t,e)}function Di(t,e){return null!=t&&e in Ct(t)}function Li(t,e,n){for(var a=n?Ne:Oe,o=t[0].length,s=t.length,u=s,l=i(s),c=1/0,d=[];u--;){var h=t[u];u&&e&&(h=ke(h,Qe(e))),c=wn(h.length,c),l[u]=!n&&(e||o>=120&&h.length>=120)?new Kn(u&&h):r}h=t[0];var p=-1,f=l[0];t:for(;++p=s?u:u*("desc"==n[i]?-1:1)}return t.index-e.index}(t,e,n)}))}function zi(t,e,n){for(var i=-1,r=e.length,a={};++i-1;)s!==t&&Xt.call(s,u,1),Xt.call(t,u,1);return t}function Yi(t,e){for(var n=t?e.length:0,i=n-1;n--;){var r=e[n];if(n==i||r!==a){var a=r;va(r)?Xt.call(t,r,1):hr(t,r)}}return t}function Ki(t,e){return t+ye(En()*(e-t+1))}function Xi(t,e){var n="";if(!t||e<1||e>f)return n;do{e%2&&(n+=t),(e=ye(e/2))&&(t+=t)}while(e);return n}function Ji(t,e){return Ma(Ca(t,e,ru),t+"")}function Zi(t){return Zn(qs(t))}function Qi(t,e){var n=qs(t);return ka(n,ui(e,0,n.length))}function tr(t,e,n,i){if(!es(t))return t;for(var a=-1,o=(e=wr(e,t)).length,s=o-1,u=t;null!=u&&++aa?0:a+e),(n=n>a?a:n)<0&&(n+=a),a=e>n?0:n-e>>>0,e>>>=0;for(var o=i(a);++r>>1,o=t[a];null!==o&&!ls(o)&&(n?o<=e:o=200){var l=e?null:Xr(t);if(l)return hn(l);o=!1,r=en,u=new Kn}else u=e?[]:s;t:for(;++i=i?t:rr(t,e,n)}var Er=re||function(t){return me.clearTimeout(t)};function xr(t,e){if(e)return t.slice();var n=t.length,i=zt?zt(n):new t.constructor(n);return t.copy(i),i}function Tr(t){var e=new t.constructor(t.byteLength);return new Wt(e).set(new Wt(t)),e}function Ir(t,e){var n=e?Tr(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}function Cr(t,e){if(t!==e){var n=t!==r,i=null===t,a=t==t,o=ls(t),s=e!==r,u=null===e,l=e==e,c=ls(e);if(!u&&!c&&!o&&t>e||o&&s&&l&&!u&&!c||i&&s&&l||!n&&l||!a)return 1;if(!i&&!o&&!c&&t1?n[a-1]:r,s=a>2?n[2]:r;for(o=t.length>3&&"function"==typeof o?(a--,o):r,s&&wa(n[0],n[1],s)&&(o=a<3?r:o,a=1),e=Ct(e);++i-1?a[o?e[s]:s]:r}}function Br(t){return ia((function(e){var n=e.length,i=n,o=Hn.prototype.thru;for(t&&e.reverse();i--;){var s=e[i];if("function"!=typeof s)throw new Lt(a);if(o&&!u&&"wrapper"==sa(s))var u=new Hn([],!0)}for(i=u?i:n;++i1&&w.reverse(),p&&cu))return!1;var c=o.get(t),d=o.get(e);if(c&&d)return c==e&&d==t;var h=-1,p=!0,f=2&n?new Kn:r;for(o.set(t,e),o.set(e,t);++h-1&&t%1==0&&t1?"& ":"")+e[i],e=e.join(n>2?", ":" "),t.replace(ut,"{\n/* [wrapped with "+e+"] */\n")}(i,function(t,e){return De(b,(function(n){var i="_."+n[0];e&n[1]&&!Oe(t,i)&&t.push(i)})),t.sort()}(function(t){var e=t.match(lt);return e?e[1].split(ct):[]}(i),n)))}function Na(t){var e=0,n=0;return function(){var i=_n(),a=16-(i-n);if(n=i,a>0){if(++e>=800)return arguments[0]}else e=0;return t.apply(r,arguments)}}function ka(t,e){var n=-1,i=t.length,a=i-1;for(e=e===r?i:e;++n1?t[e-1]:r;return n="function"==typeof n?(t.pop(),n):r,ao(t,n)}));function po(t){var e=qn(t);return e.__chain__=!0,e}function fo(t,e){return e(t)}var mo=ia((function(t){var e=t.length,n=e?t[0]:0,i=this.__wrapped__,a=function(e){return si(e,t)};return!(e>1||this.__actions__.length)&&i instanceof Wn&&va(n)?((i=i.slice(n,+n+(e?1:0))).__actions__.push({func:fo,args:[a],thisArg:r}),new Hn(i,this.__chain__).thru((function(t){return e&&!t.length&&t.push(r),t}))):this.thru(a)}));var yo=Mr((function(t,e,n){Pt.call(t,n)?++t[n]:oi(t,n,1)}));var bo=$r(Ua),go=$r(Ha);function vo(t,e){return(Wo(t)?De:pi)(t,la(e,3))}function wo(t,e){return(Wo(t)?Le:fi)(t,la(e,3))}var _o=Mr((function(t,e,n){Pt.call(t,n)?t[n].push(e):oi(t,n,[e])}));var Ao=Ji((function(t,e,n){var r=-1,a="function"==typeof e,o=Go(t)?i(t.length):[];return pi(t,(function(t){o[++r]=a?Ce(e,t,n):Fi(t,e,n)})),o})),Eo=Mr((function(t,e,n){oi(t,n,e)}));function xo(t,e){return(Wo(t)?ke:Bi)(t,la(e,3))}var To=Mr((function(t,e,n){t[n?0:1].push(e)}),(function(){return[[],[]]}));var Io=Ji((function(t,e){if(null==t)return[];var n=e.length;return n>1&&wa(t,e[0],e[1])?e=[]:n>2&&wa(e[0],e[1],e[2])&&(e=[e[0]]),Wi(t,gi(e,1),[])})),Co=ce||function(){return me.Date.now()};function So(t,e,n){return e=n?r:e,e=t&&null==e?t.length:e,Zr(t,d,r,r,r,r,e)}function Do(t,e){var n;if("function"!=typeof e)throw new Lt(a);return t=ms(t),function(){return--t>0&&(n=e.apply(this,arguments)),t<=1&&(e=r),n}}var Lo=Ji((function(t,e,n){var i=1;if(n.length){var r=dn(n,ua(Lo));i|=l}return Zr(t,i,e,n,r)})),Fo=Ji((function(t,e,n){var i=3;if(n.length){var r=dn(n,ua(Fo));i|=l}return Zr(e,i,t,n,r)}));function Mo(t,e,n){var i,o,s,u,l,c,d=0,h=!1,p=!1,f=!0;if("function"!=typeof t)throw new Lt(a);function m(e){var n=i,a=o;return i=o=r,d=e,u=t.apply(a,n)}function y(t){var n=t-c;return c===r||n>=e||n<0||p&&t-d>=s}function b(){var t=Co();if(y(t))return g(t);l=Fa(b,function(t){var n=e-(t-c);return p?wn(n,s-(t-d)):n}(t))}function g(t){return l=r,f&&i?m(t):(i=o=r,u)}function v(){var t=Co(),n=y(t);if(i=arguments,o=this,c=t,n){if(l===r)return function(t){return d=t,l=Fa(b,e),h?m(t):u}(c);if(p)return Er(l),l=Fa(b,e),m(c)}return l===r&&(l=Fa(b,e)),u}return e=bs(e)||0,es(n)&&(h=!!n.leading,s=(p="maxWait"in n)?vn(bs(n.maxWait)||0,e):s,f="trailing"in n?!!n.trailing:f),v.cancel=function(){l!==r&&Er(l),d=0,i=c=o=l=r},v.flush=function(){return l===r?u:g(Co())},v}var Oo=Ji((function(t,e){return di(t,1,e)})),No=Ji((function(t,e,n){return di(t,bs(e)||0,n)}));function ko(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new Lt(a);var n=function(){var i=arguments,r=e?e.apply(this,i):i[0],a=n.cache;if(a.has(r))return a.get(r);var o=t.apply(this,i);return n.cache=a.set(r,o)||a,o};return n.cache=new(ko.Cache||Yn),n}function Po(t){if("function"!=typeof t)throw new Lt(a);return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}ko.Cache=Yn;var Vo=_r((function(t,e){var n=(e=1==e.length&&Wo(e[0])?ke(e[0],Qe(la())):ke(gi(e,1),Qe(la()))).length;return Ji((function(i){for(var r=-1,a=wn(i.length,n);++r=e})),Ho=Mi(function(){return arguments}())?Mi:function(t){return ns(t)&&Pt.call(t,"callee")&&!Kt.call(t,"callee")},Wo=i.isArray,zo=_e?Qe(_e):function(t){return ns(t)&&Ii(t)==N};function Go(t){return null!=t&&ts(t.length)&&!Zo(t)}function Yo(t){return ns(t)&&Go(t)}var Ko=ve||bu,Xo=Ae?Qe(Ae):function(t){return ns(t)&&Ii(t)==_};function Jo(t){if(!ns(t))return!1;var e=Ii(t);return e==A||"[object DOMException]"==e||"string"==typeof t.message&&"string"==typeof t.name&&!as(t)}function Zo(t){if(!es(t))return!1;var e=Ii(t);return e==E||e==x||"[object AsyncFunction]"==e||"[object Proxy]"==e}function Qo(t){return"number"==typeof t&&t==ms(t)}function ts(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=f}function es(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}function ns(t){return null!=t&&"object"==typeof t}var is=Ee?Qe(Ee):function(t){return ns(t)&&ma(t)==T};function rs(t){return"number"==typeof t||ns(t)&&Ii(t)==I}function as(t){if(!ns(t)||Ii(t)!=C)return!1;var e=Gt(t);if(null===e)return!0;var n=Pt.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&kt.call(n)==Bt}var os=xe?Qe(xe):function(t){return ns(t)&&Ii(t)==D};var ss=Te?Qe(Te):function(t){return ns(t)&&ma(t)==L};function us(t){return"string"==typeof t||!Wo(t)&&ns(t)&&Ii(t)==F}function ls(t){return"symbol"==typeof t||ns(t)&&Ii(t)==M}var cs=Ie?Qe(Ie):function(t){return ns(t)&&ts(t.length)&&!!ue[Ii(t)]};var ds=Gr($i),hs=Gr((function(t,e){return t<=e}));function ps(t){if(!t)return[];if(Go(t))return us(t)?mn(t):Lr(t);if(Zt&&t[Zt])return function(t){for(var e,n=[];!(e=t.next()).done;)n.push(e.value);return n}(t[Zt]());var e=ma(t);return(e==T?ln:e==L?hn:qs)(t)}function fs(t){return t?(t=bs(t))===p||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}function ms(t){var e=fs(t),n=e%1;return e==e?n?e-n:e:0}function ys(t){return t?ui(ms(t),0,y):0}function bs(t){if("number"==typeof t)return t;if(ls(t))return m;if(es(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=es(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=Ze(t);var n=bt.test(t);return n||vt.test(t)?he(t.slice(2),n?2:8):yt.test(t)?m:+t}function gs(t){return Fr(t,Os(t))}function vs(t){return null==t?"":cr(t)}var ws=Or((function(t,e){if(xa(e)||Go(e))Fr(e,Ms(e),t);else for(var n in e)Pt.call(e,n)&&ni(t,n,e[n])})),_s=Or((function(t,e){Fr(e,Os(e),t)})),As=Or((function(t,e,n,i){Fr(e,Os(e),t,i)})),Es=Or((function(t,e,n,i){Fr(e,Ms(e),t,i)})),xs=ia(si);var Ts=Ji((function(t,e){t=Ct(t);var n=-1,i=e.length,a=i>2?e[2]:r;for(a&&wa(e[0],e[1],a)&&(i=1);++n1),e})),Fr(t,aa(t),n),i&&(n=li(n,7,ea));for(var r=e.length;r--;)hr(n,e[r]);return n}));var Vs=ia((function(t,e){return null==t?{}:function(t,e){return zi(t,e,(function(e,n){return Ss(t,n)}))}(t,e)}));function Rs(t,e){if(null==t)return{};var n=ke(aa(t),(function(t){return[t]}));return e=la(e),zi(t,n,(function(t,n){return e(t,n[0])}))}var $s=Jr(Ms),Bs=Jr(Os);function qs(t){return null==t?[]:tn(t,Ms(t))}var js=Vr((function(t,e,n){return e=e.toLowerCase(),t+(n?Us(e):e)}));function Us(t){return Js(vs(t).toLowerCase())}function Hs(t){return(t=vs(t))&&t.replace(_t,an).replace(ee,"")}var Ws=Vr((function(t,e,n){return t+(n?"-":"")+e.toLowerCase()})),zs=Vr((function(t,e,n){return t+(n?" ":"")+e.toLowerCase()})),Gs=Pr("toLowerCase");var Ys=Vr((function(t,e,n){return t+(n?"_":"")+e.toLowerCase()}));var Ks=Vr((function(t,e,n){return t+(n?" ":"")+Js(e)}));var Xs=Vr((function(t,e,n){return t+(n?" ":"")+e.toUpperCase()})),Js=Pr("toUpperCase");function Zs(t,e,n){return t=vs(t),(e=n?r:e)===r?function(t){return ae.test(t)}(t)?function(t){return t.match(ie)||[]}(t):function(t){return t.match(dt)||[]}(t):t.match(e)||[]}var Qs=Ji((function(t,e){try{return Ce(t,r,e)}catch(t){return Jo(t)?t:new xt(t)}})),tu=ia((function(t,e){return De(e,(function(e){e=Va(e),oi(t,e,Lo(t[e],t))})),t}));function eu(t){return function(){return t}}var nu=Br(),iu=Br(!0);function ru(t){return t}function au(t){return Pi("function"==typeof t?t:li(t,1))}var ou=Ji((function(t,e){return function(n){return Fi(n,t,e)}})),su=Ji((function(t,e){return function(n){return Fi(t,n,e)}}));function uu(t,e,n){var i=Ms(e),r=Ei(e,i);null!=n||es(e)&&(r.length||!i.length)||(n=e,e=t,t=this,r=Ei(e,Ms(e)));var a=!(es(n)&&"chain"in n&&!n.chain),o=Zo(t);return De(r,(function(n){var i=e[n];t[n]=i,o&&(t.prototype[n]=function(){var e=this.__chain__;if(a||e){var n=t(this.__wrapped__);return(n.__actions__=Lr(this.__actions__)).push({func:i,args:arguments,thisArg:t}),n.__chain__=e,n}return i.apply(t,Pe([this.value()],arguments))})})),t}function lu(){}var cu=Hr(ke),du=Hr(Fe),hu=Hr($e);function pu(t){return _a(t)?Ge(Va(t)):function(t){return function(e){return xi(e,t)}}(t)}var fu=zr(),mu=zr(!0);function yu(){return[]}function bu(){return!1}var gu=Ur((function(t,e){return t+e}),0),vu=Kr("ceil"),wu=Ur((function(t,e){return t/e}),1),_u=Kr("floor");var Au,Eu=Ur((function(t,e){return t*e}),1),xu=Kr("round"),Tu=Ur((function(t,e){return t-e}),0);return qn.after=function(t,e){if("function"!=typeof e)throw new Lt(a);return t=ms(t),function(){if(--t<1)return e.apply(this,arguments)}},qn.ary=So,qn.assign=ws,qn.assignIn=_s,qn.assignInWith=As,qn.assignWith=Es,qn.at=xs,qn.before=Do,qn.bind=Lo,qn.bindAll=tu,qn.bindKey=Fo,qn.castArray=function(){if(!arguments.length)return[];var t=arguments[0];return Wo(t)?t:[t]},qn.chain=po,qn.chunk=function(t,e,n){e=(n?wa(t,e,n):e===r)?1:vn(ms(e),0);var a=null==t?0:t.length;if(!a||e<1)return[];for(var o=0,s=0,u=i(fe(a/e));oa?0:a+n),(i=i===r||i>a?a:ms(i))<0&&(i+=a),i=n>i?0:ys(i);n>>0)?(t=vs(t))&&("string"==typeof e||null!=e&&!os(e))&&!(e=cr(e))&&un(t)?Ar(mn(t),0,n):t.split(e,n):[]},qn.spread=function(t,e){if("function"!=typeof t)throw new Lt(a);return e=null==e?0:vn(ms(e),0),Ji((function(n){var i=n[e],r=Ar(n,0,e);return i&&Pe(r,i),Ce(t,this,r)}))},qn.tail=function(t){var e=null==t?0:t.length;return e?rr(t,1,e):[]},qn.take=function(t,e,n){return t&&t.length?rr(t,0,(e=n||e===r?1:ms(e))<0?0:e):[]},qn.takeRight=function(t,e,n){var i=null==t?0:t.length;return i?rr(t,(e=i-(e=n||e===r?1:ms(e)))<0?0:e,i):[]},qn.takeRightWhile=function(t,e){return t&&t.length?fr(t,la(e,3),!1,!0):[]},qn.takeWhile=function(t,e){return t&&t.length?fr(t,la(e,3)):[]},qn.tap=function(t,e){return e(t),t},qn.throttle=function(t,e,n){var i=!0,r=!0;if("function"!=typeof t)throw new Lt(a);return es(n)&&(i="leading"in n?!!n.leading:i,r="trailing"in n?!!n.trailing:r),Mo(t,e,{leading:i,maxWait:e,trailing:r})},qn.thru=fo,qn.toArray=ps,qn.toPairs=$s,qn.toPairsIn=Bs,qn.toPath=function(t){return Wo(t)?ke(t,Va):ls(t)?[t]:Lr(Pa(vs(t)))},qn.toPlainObject=gs,qn.transform=function(t,e,n){var i=Wo(t),r=i||Ko(t)||cs(t);if(e=la(e,4),null==n){var a=t&&t.constructor;n=r?i?new a:[]:es(t)&&Zo(a)?jn(Gt(t)):{}}return(r?De:_i)(t,(function(t,i,r){return e(n,t,i,r)})),n},qn.unary=function(t){return So(t,1)},qn.union=eo,qn.unionBy=no,qn.unionWith=io,qn.uniq=function(t){return t&&t.length?dr(t):[]},qn.uniqBy=function(t,e){return t&&t.length?dr(t,la(e,2)):[]},qn.uniqWith=function(t,e){return e="function"==typeof e?e:r,t&&t.length?dr(t,r,e):[]},qn.unset=function(t,e){return null==t||hr(t,e)},qn.unzip=ro,qn.unzipWith=ao,qn.update=function(t,e,n){return null==t?t:pr(t,e,vr(n))},qn.updateWith=function(t,e,n,i){return i="function"==typeof i?i:r,null==t?t:pr(t,e,vr(n),i)},qn.values=qs,qn.valuesIn=function(t){return null==t?[]:tn(t,Os(t))},qn.without=oo,qn.words=Zs,qn.wrap=function(t,e){return Ro(vr(e),t)},qn.xor=so,qn.xorBy=uo,qn.xorWith=lo,qn.zip=co,qn.zipObject=function(t,e){return br(t||[],e||[],ni)},qn.zipObjectDeep=function(t,e){return br(t||[],e||[],tr)},qn.zipWith=ho,qn.entries=$s,qn.entriesIn=Bs,qn.extend=_s,qn.extendWith=As,uu(qn,qn),qn.add=gu,qn.attempt=Qs,qn.camelCase=js,qn.capitalize=Us,qn.ceil=vu,qn.clamp=function(t,e,n){return n===r&&(n=e,e=r),n!==r&&(n=(n=bs(n))==n?n:0),e!==r&&(e=(e=bs(e))==e?e:0),ui(bs(t),e,n)},qn.clone=function(t){return li(t,4)},qn.cloneDeep=function(t){return li(t,5)},qn.cloneDeepWith=function(t,e){return li(t,5,e="function"==typeof e?e:r)},qn.cloneWith=function(t,e){return li(t,4,e="function"==typeof e?e:r)},qn.conformsTo=function(t,e){return null==e||ci(t,e,Ms(e))},qn.deburr=Hs,qn.defaultTo=function(t,e){return null==t||t!=t?e:t},qn.divide=wu,qn.endsWith=function(t,e,n){t=vs(t),e=cr(e);var i=t.length,a=n=n===r?i:ui(ms(n),0,i);return(n-=e.length)>=0&&t.slice(n,a)==e},qn.eq=qo,qn.escape=function(t){return(t=vs(t))&&J.test(t)?t.replace(K,on):t},qn.escapeRegExp=function(t){return(t=vs(t))&&at.test(t)?t.replace(rt,"\\$&"):t},qn.every=function(t,e,n){var i=Wo(t)?Fe:mi;return n&&wa(t,e,n)&&(e=r),i(t,la(e,3))},qn.find=bo,qn.findIndex=Ua,qn.findKey=function(t,e){return qe(t,la(e,3),_i)},qn.findLast=go,qn.findLastIndex=Ha,qn.findLastKey=function(t,e){return qe(t,la(e,3),Ai)},qn.floor=_u,qn.forEach=vo,qn.forEachRight=wo,qn.forIn=function(t,e){return null==t?t:vi(t,la(e,3),Os)},qn.forInRight=function(t,e){return null==t?t:wi(t,la(e,3),Os)},qn.forOwn=function(t,e){return t&&_i(t,la(e,3))},qn.forOwnRight=function(t,e){return t&&Ai(t,la(e,3))},qn.get=Cs,qn.gt=jo,qn.gte=Uo,qn.has=function(t,e){return null!=t&&ya(t,e,Si)},qn.hasIn=Ss,qn.head=za,qn.identity=ru,qn.includes=function(t,e,n,i){t=Go(t)?t:qs(t),n=n&&!i?ms(n):0;var r=t.length;return n<0&&(n=vn(r+n,0)),us(t)?n<=r&&t.indexOf(e,n)>-1:!!r&&Ue(t,e,n)>-1},qn.indexOf=function(t,e,n){var i=null==t?0:t.length;if(!i)return-1;var r=null==n?0:ms(n);return r<0&&(r=vn(i+r,0)),Ue(t,e,r)},qn.inRange=function(t,e,n){return e=fs(e),n===r?(n=e,e=0):n=fs(n),function(t,e,n){return t>=wn(e,n)&&t=-9007199254740991&&t<=f},qn.isSet=ss,qn.isString=us,qn.isSymbol=ls,qn.isTypedArray=cs,qn.isUndefined=function(t){return t===r},qn.isWeakMap=function(t){return ns(t)&&ma(t)==O},qn.isWeakSet=function(t){return ns(t)&&"[object WeakSet]"==Ii(t)},qn.join=function(t,e){return null==t?"":Be.call(t,e)},qn.kebabCase=Ws,qn.last=Xa,qn.lastIndexOf=function(t,e,n){var i=null==t?0:t.length;if(!i)return-1;var a=i;return n!==r&&(a=(a=ms(n))<0?vn(i+a,0):wn(a,i-1)),e==e?function(t,e,n){for(var i=n+1;i--;)if(t[i]===e)return i;return i}(t,e,a):je(t,We,a,!0)},qn.lowerCase=zs,qn.lowerFirst=Gs,qn.lt=ds,qn.lte=hs,qn.max=function(t){return t&&t.length?yi(t,ru,Ci):r},qn.maxBy=function(t,e){return t&&t.length?yi(t,la(e,2),Ci):r},qn.mean=function(t){return ze(t,ru)},qn.meanBy=function(t,e){return ze(t,la(e,2))},qn.min=function(t){return t&&t.length?yi(t,ru,$i):r},qn.minBy=function(t,e){return t&&t.length?yi(t,la(e,2),$i):r},qn.stubArray=yu,qn.stubFalse=bu,qn.stubObject=function(){return{}},qn.stubString=function(){return""},qn.stubTrue=function(){return!0},qn.multiply=Eu,qn.nth=function(t,e){return t&&t.length?Hi(t,ms(e)):r},qn.noConflict=function(){return me._===this&&(me._=qt),this},qn.noop=lu,qn.now=Co,qn.pad=function(t,e,n){t=vs(t);var i=(e=ms(e))?fn(t):0;if(!e||i>=e)return t;var r=(e-i)/2;return Wr(ye(r),n)+t+Wr(fe(r),n)},qn.padEnd=function(t,e,n){t=vs(t);var i=(e=ms(e))?fn(t):0;return e&&ie){var i=t;t=e,e=i}if(n||t%1||e%1){var a=En();return wn(t+a*(e-t+de("1e-"+((a+"").length-1))),e)}return Ki(t,e)},qn.reduce=function(t,e,n){var i=Wo(t)?Ve:Ke,r=arguments.length<3;return i(t,la(e,4),n,r,pi)},qn.reduceRight=function(t,e,n){var i=Wo(t)?Re:Ke,r=arguments.length<3;return i(t,la(e,4),n,r,fi)},qn.repeat=function(t,e,n){return e=(n?wa(t,e,n):e===r)?1:ms(e),Xi(vs(t),e)},qn.replace=function(){var t=arguments,e=vs(t[0]);return t.length<3?e:e.replace(t[1],t[2])},qn.result=function(t,e,n){var i=-1,a=(e=wr(e,t)).length;for(a||(a=1,t=r);++if)return[];var n=y,i=wn(t,y);e=la(e),t-=y;for(var r=Je(i,e);++n=o)return t;var u=n-fn(i);if(u<1)return i;var l=s?Ar(s,0,u).join(""):t.slice(0,u);if(a===r)return l+i;if(s&&(u+=l.length-u),os(a)){if(t.slice(u).search(a)){var c,d=l;for(a.global||(a=St(a.source,vs(mt.exec(a))+"g")),a.lastIndex=0;c=a.exec(d);)var h=c.index;l=l.slice(0,h===r?u:h)}}else if(t.indexOf(cr(a),u)!=u){var p=l.lastIndexOf(a);p>-1&&(l=l.slice(0,p))}return l+i},qn.unescape=function(t){return(t=vs(t))&&X.test(t)?t.replace(Y,bn):t},qn.uniqueId=function(t){var e=++Vt;return vs(t)+e},qn.upperCase=Xs,qn.upperFirst=Js,qn.each=vo,qn.eachRight=wo,qn.first=za,uu(qn,(Au={},_i(qn,(function(t,e){Pt.call(qn.prototype,e)||(Au[e]=t)})),Au),{chain:!1}),qn.VERSION="4.17.21",De(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(t){qn[t].placeholder=qn})),De(["drop","take"],(function(t,e){Wn.prototype[t]=function(n){n=n===r?1:vn(ms(n),0);var i=this.__filtered__&&!e?new Wn(this):this.clone();return i.__filtered__?i.__takeCount__=wn(n,i.__takeCount__):i.__views__.push({size:wn(n,y),type:t+(i.__dir__<0?"Right":"")}),i},Wn.prototype[t+"Right"]=function(e){return this.reverse()[t](e).reverse()}})),De(["filter","map","takeWhile"],(function(t,e){var n=e+1,i=1==n||3==n;Wn.prototype[t]=function(t){var e=this.clone();return e.__iteratees__.push({iteratee:la(t,3),type:n}),e.__filtered__=e.__filtered__||i,e}})),De(["head","last"],(function(t,e){var n="take"+(e?"Right":"");Wn.prototype[t]=function(){return this[n](1).value()[0]}})),De(["initial","tail"],(function(t,e){var n="drop"+(e?"":"Right");Wn.prototype[t]=function(){return this.__filtered__?new Wn(this):this[n](1)}})),Wn.prototype.compact=function(){return this.filter(ru)},Wn.prototype.find=function(t){return this.filter(t).head()},Wn.prototype.findLast=function(t){return this.reverse().find(t)},Wn.prototype.invokeMap=Ji((function(t,e){return"function"==typeof t?new Wn(this):this.map((function(n){return Fi(n,t,e)}))})),Wn.prototype.reject=function(t){return this.filter(Po(la(t)))},Wn.prototype.slice=function(t,e){t=ms(t);var n=this;return n.__filtered__&&(t>0||e<0)?new Wn(n):(t<0?n=n.takeRight(-t):t&&(n=n.drop(t)),e!==r&&(n=(e=ms(e))<0?n.dropRight(-e):n.take(e-t)),n)},Wn.prototype.takeRightWhile=function(t){return this.reverse().takeWhile(t).reverse()},Wn.prototype.toArray=function(){return this.take(y)},_i(Wn.prototype,(function(t,e){var n=/^(?:filter|find|map|reject)|While$/.test(e),i=/^(?:head|last)$/.test(e),a=qn[i?"take"+("last"==e?"Right":""):e],o=i||/^find/.test(e);a&&(qn.prototype[e]=function(){var e=this.__wrapped__,s=i?[1]:arguments,u=e instanceof Wn,l=s[0],c=u||Wo(e),d=function(t){var e=a.apply(qn,Pe([t],s));return i&&h?e[0]:e};c&&n&&"function"==typeof l&&1!=l.length&&(u=c=!1);var h=this.__chain__,p=!!this.__actions__.length,f=o&&!h,m=u&&!p;if(!o&&c){e=m?e:new Wn(this);var y=t.apply(e,s);return y.__actions__.push({func:fo,args:[d],thisArg:r}),new Hn(y,h)}return f&&m?t.apply(this,s):(y=this.thru(d),f?i?y.value()[0]:y.value():y)})})),De(["pop","push","shift","sort","splice","unshift"],(function(t){var e=Ft[t],n=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",i=/^(?:pop|shift)$/.test(t);qn.prototype[t]=function(){var t=arguments;if(i&&!this.__chain__){var r=this.value();return e.apply(Wo(r)?r:[],t)}return this[n]((function(n){return e.apply(Wo(n)?n:[],t)}))}})),_i(Wn.prototype,(function(t,e){var n=qn[e];if(n){var i=n.name+"";Pt.call(Mn,i)||(Mn[i]=[]),Mn[i].push({name:e,func:n})}})),Mn[qr(r,2).name]=[{name:"wrapper",func:r}],Wn.prototype.clone=function(){var t=new Wn(this.__wrapped__);return t.__actions__=Lr(this.__actions__),t.__dir__=this.__dir__,t.__filtered__=this.__filtered__,t.__iteratees__=Lr(this.__iteratees__),t.__takeCount__=this.__takeCount__,t.__views__=Lr(this.__views__),t},Wn.prototype.reverse=function(){if(this.__filtered__){var t=new Wn(this);t.__dir__=-1,t.__filtered__=!0}else(t=this.clone()).__dir__*=-1;return t},Wn.prototype.value=function(){var t=this.__wrapped__.value(),e=this.__dir__,n=Wo(t),i=e<0,r=n?t.length:0,a=function(t,e,n){var i=-1,r=n.length;for(;++i=this.__values__.length;return{done:t,value:t?r:this.__values__[this.__index__++]}},qn.prototype.plant=function(t){for(var e,n=this;n instanceof Un;){var i=$a(n);i.__index__=0,i.__values__=r,e?a.__wrapped__=i:e=i;var a=i;n=n.__wrapped__}return a.__wrapped__=t,e},qn.prototype.reverse=function(){var t=this.__wrapped__;if(t instanceof Wn){var e=t;return this.__actions__.length&&(e=new Wn(this)),(e=e.reverse()).__actions__.push({func:fo,args:[to],thisArg:r}),new Hn(e,this.__chain__)}return this.thru(to)},qn.prototype.toJSON=qn.prototype.valueOf=qn.prototype.value=function(){return mr(this.__wrapped__,this.__actions__)},qn.prototype.first=qn.prototype.head,Zt&&(qn.prototype[Zt]=function(){return this}),qn}();me._=gn,(i=function(){return gn}.call(e,n,e,t))===r||(t.exports=i)}.call(this)}},e={};function n(i){var r=e[i];if(void 0!==r)return r.exports;var a=e[i]={id:i,loaded:!1,exports:{}};return t[i].call(a.exports,a,a.exports,n),a.loaded=!0,a.exports}n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),n.nmd=function(t){return t.paths=[],t.children||(t.children=[]),t},function(){"use strict";window.Alpine.data("accordion",(()=>({accordionItems:[],init(){window.phoenix.bus.subscribe("ACCORDION","FETCH_ACCORDION_ITEMS_SUCCESS",this.renderPanels?.bind(this))},renderPanels(t){this.accordionItems=t?.payload},triggerModal(t){window.phoenix.bus.publish("MODAL","FETCH_MODAL_CONTENT_SUCCESS",{payload:{content:t}})}}))),window.Alpine?.data("actionSelector",(()=>({selectedOption:null,handleAction(){const t=this.$el?.dataset.xprActionChannel,e=this.$el?.querySelector(":checked")?.getAttribute("data-xpr-action-topic");window.phoenix.bus.publish(t,e,{payload:{selectedValue:this.selectedOption}})}})));const t={appName:"phoenix-experience",className:"address"};window.Alpine.data("address",((e,n,i,r,a)=>({formChannel:a||"FORM",inputs:{},isFormValid:!1,formValidation:null,canShowAddressOptions:!1,addressType:e,addressOptions:[],componentId:n,componentIdSymbol:Symbol(n),currentAddress:{addressLine1:"",addressLine2:"",city:"",state:"",zipCode:""},editAddress:{addressLine1:"",addressLine2:"",city:"",state:"",zipCode:""},name:{first:"",last:""},hideEditAddressForm:!0,showPaymentSameAs:!0,isAddressInvalid:!1,relatedSameAsAddressType:i,showSuggestedAddress:!1,showAddressForm:!0,showCheckBox:!0,isAwayPlanCart:!1,recommendedAddress:{},async init(){this.isAwayPlanCart=await window.phoenix.persistedState.get("IS_AWAY_PLAN_CART")??!1,this.subscribeToAddress(),this.subscribeToButtonEvents(),this.subscribeToIncomingFormData(),this.subscribeToAddressFormSectionVisibility(),"SERVICE"!==this.addressType&&(this.subscribeToGeocoders(),this.subscribeToSuggestedAddresses(),this.$watch?.("hideEditAddressForm",(t=>{this.$nextTick?.((()=>{if("boolean"==typeof t&&!t&&this.$el&&window?.phoenix?.experience?.utils?.FormValidation){this.inputElements=this.$el.querySelectorAll(`[data-xpr-field*=${this.componentId}]`);const t=this.$el.querySelector(`form[data-address-edit-form*=${this.componentId}]`);this.formValidation=new window.phoenix.experience.utils.FormValidation(this.inputElements,t),this.inputs=this.formValidation?.inputs,this.isFormValid=this.formValidation?.validate(),window.phoenix.bus.publish("FORM","REGISTER",{id:this.componentIdSymbol}),this.publishFormValidity()}else this.editAddress={addressLine1:"",addressLine2:"",city:"",state:"",zipCode:""},this.showSuggestedAddress=!1,this.isAddressInvalid=!1,window.phoenix.bus.publish("FORM","UNREGISTER",{id:this.componentIdSymbol})}))})),("CARD"===e||r)&&(this.hideEditAddressForm=!1),"BILLING"===e&&"/buy/create-account"===window.location.pathname&&this.isAwayPlanCart&&window.phoenix.checkFeatureFlag("isAwayPlanEnabled")&&(this.hideEditAddressForm=!1,this.showCheckBox=!1))},change(t){const e=this.inputs[t.target.name];e&&("focusout"===t.type&&(e.blurred=!0),this.isAddressInvalid=!1,this.isFormValid=this.formValidation?.validate()??!0,this.formValidation?.handleFormChange(t),this.publishFormValidity())},validateInputDirtyState(t,e){this.inputs[t]?.nodeTrack?.setAttribute("data-complete",e?.length>=1?"true":"false")},comboboxEscapePressed(){this.canShowAddressOptions||((this.$refs?.addressLine1Input).value=""),this.canShowAddressOptions=!1,this.$focus?.focus(this.$refs?.addressLine1Input)},displayDropdown(){return this.addressOptions.length>0&&this.canShowAddressOptions},fetchAddressOptions(){this.editAddress.addressLine1.length>=2?window.phoenix.bus.publish("GEOCODERS_ADDRESS_INFO","FETCH_GEOCODERS_ADDRESS_INFO",{payload:{q:this.editAddress.addressLine1,key:"",expandAddress:"0",autocomplete:!0},id:this.componentIdSymbol}):this.addressOptions=[]},focusOnOuterOptions(t){this.$nextTick?.((()=>{this.$refs?.options&&(t?this.$focus?.within(this.$refs.options).first():this.$focus?.within(this.$refs.options).last())}))},selectAddress(t){window.phoenix.bus.publish("GEOCODERS_ADDRESS_INFO","FETCH_GEOCODERS_ADDRESS_INFO",{payload:{q:t,key:"",expandAddress:"1",autocomplete:!1},id:this.componentIdSymbol})},toggleAddressForm(){this.hideEditAddressForm=!this.hideEditAddressForm},publishFormValidity(){const t=this.isFormValid?"VALID":"INVALID";window.phoenix.bus.publish(this.formChannel,t,{payload:{formData:{address:{addressLine1:this.editAddress.addressLine1,addressLine2:this.editAddress.addressLine2||void 0,cityName:this.editAddress.city??"",stateCode:this.editAddress.state??"",postalCode:this.editAddress.zipCode??""},addressTypes:[this.addressType],name:{first:this.name.first,last:this.name.last}},isValid:this.isFormValid},id:this.componentIdSymbol})},subscribeToAddress(){this.addressType?window.phoenix.bus.subscribe("CART","FETCHED_CART_SUCCESS",this.handleSubscribeToAddress.bind(this)):window.phoenix.log.error(`invalid addressType ${this.addressType}`,t)},handleSubscribeToAddress(e){switch(this.addressType){case"BILLING":this.currentAddress=e?.payload?.billing.billingAddress;break;case"SHIPPING":this.currentAddress=e?.payload?.shipping.shippingAddress;break;case"CARD":this.currentAddress=e?.payload?.payment.paymentAddress;break;case"SERVICE":this.currentAddress=e?.payload?.serviceAddress.address;break;default:window.phoenix.log.error(`invalid addressType ${this.addressType}`,t)}},subscribeToGeocoders(){window.phoenix.bus.subscribe("GEOCODERS_ADDRESS_INFO","FETCH_GEOCODERS_ADDRESS_INFO_AUTOCOMPLETE_SUCCESS",this.dropdownAutocomplete.bind(this)),window.phoenix.bus.subscribe("GEOCODERS_ADDRESS_INFO","FETCH_GEOCODERS_ADDRESS_INFO_SELECTION_SUCCESS",this.dropdownOptionSelect.bind(this)),window.phoenix.bus.subscribe("GEOCODERS_ADDRESS_INFO","FETCH_GEOCODERS_ADDRESS_INFO_SUCCESS",this.onVerifyAddressSuccess.bind(this))},dropdownAutocomplete(t){t?.id===this.componentIdSymbol&&(this.addressOptions=t?.payload?.addressOptions.slice(0,5)??[],this.canShowAddressOptions=!0)},dropdownOptionSelect(t){if(t?.id===this.componentIdSymbol){const e=t?.payload?.meta;this.editAddress={...this.editAddress,addressLine1:e?.street1??"",addressLine2:this.editAddress.addressLine2,city:e?.city,state:e?.state,zipCode:e?.zipCode},this.validateInputDirtyState("city",e?.city??""),this.validateInputDirtyState("state",e?.state??""),this.validateInputDirtyState("zipCode",e?.zipCode??""),this.canShowAddressOptions=!1,this.$focus?.focus(this.$refs?.addressLine1Input),this.verifyFormOnNextTick()}},subscribeToSuggestedAddresses(){window.phoenix.bus.subscribe("ADDRESS","SUGGESTED_OR_INVALID_ADDRESS",this.addressValidation.bind(this))},addressValidation(t){if(!this.hideEditAddressForm){const e=t?.payload?.addressInfo.find((t=>t.addressTypes.includes(this.addressType)));"SUGGESTED_ADDRESS"===e?.addressStatusCode?(this.editAddress={addressLine1:e.address.addressLine1,addressLine2:e.address.addressLine2,city:e.address.cityName,state:e.address.stateCode,zipCode:e.address.postalCode},this.showSuggestedAddress=!0,this.verifyFormOnNextTick(),window.phoenix.bus.publish("ACTIVITY_SPINNER","HIDE")):"INVALID_ADDRESS"===e?.addressStatusCode&&(this.isAddressInvalid=!0,window.phoenix.bus.publish("FORM","INVALID",{id:this.componentIdSymbol}),window.phoenix.bus.publish("ACTIVITY_SPINNER","HIDE"))}},verifyFormOnNextTick(){this.$nextTick?.((()=>{this.isFormValid=this.formValidation?.validate()??!0,this.publishFormValidity()}))},subscribeToButtonEvents(){window.phoenix.bus.subscribe("ADDRESS","INITIATE_ADDRESS_VERIFICATION",this.initiateAddressVerification.bind(this))},subscribeToIncomingFormData(){window.phoenix.bus.subscribe("ADDRESS","GET_ADDRESS_DETAILS",this.handleAddressFormData?.bind(this))},subscribeToAddressFormSectionVisibility(){window.phoenix.bus.subscribe("ADDRESS","ADDRESS_FORM_SECTION_VISIBILITY",this.handleAddressFormSectionVisibility.bind(this))},handleAddressFormSectionVisibility(t){const e=t?.payload;e&&Object.keys(e).forEach((t=>{"showSuggestedAddress"!==t&&"showAddressForm"!==t||(this[t]=e[t])})),e?.showAddressForm&&(this.editAddress={...this.editAddress},this.name={...this.name})},initiateAddressVerification(t){window.phoenix.bus.publish("GEOCODERS_ADDRESS_INFO","FETCH_GEOCODERS_ADDRESS_INFO",{payload:{q:`${t?.payload?.addressLine1}, ${t?.payload?.city}, ${t?.payload?.state} ${t?.payload?.zipCode}`,key:"",expandAddress:"1",autocomplete:!1,verifyAddress:!0},id:this.componentIdSymbol}),window.phoenix.bus.publish("ACTIVITY_SPINNER","SHOW")},onVerifyAddressSuccess(t){window.phoenix.bus.publish("ACTIVITY_SPINNER","HIDE");const{payload:e,id:n}=t;if(n===this.componentIdSymbol){const t=e?.meta;this.recommendedAddress={addressLine1:t?.street1,addressLine2:this.editAddress.addressLine2,city:t?.city,state:t?.state,zipCode:t?.zipCode},this.publishRecommendedAddress(this.recommendedAddress)}},publishRecommendedAddress(t){window.phoenix.bus.publish("ADDRESS","PUBLISH_RECOMMENDED_ADDRESS",{payload:t})},handleAddressFormData(t){const e=t?.payload;e?.address&&(this.editAddress={...e.address}),e?.name&&(this.name={...e.name}),this.verifyFormOnNextTick()}}))),window.Alpine.data("autocomplete",(()=>({autocompleteValue:"",listOptions:[],factoryOption:[],canShowListOptions:!1,init(){const t=this.$refs?.options?.getAttribute("data-options");this.listOptions=t?JSON.parse(t):this.factoryOption},displayAutocompleteDropdown(){return(this.listOptions?.length??0)>0&&this.canShowListOptions},filteredListOptions(t){return t&&(this.autocompleteValue=t),this.listOptions?.filter((t=>t.text.toLowerCase().startsWith(this.autocompleteValue?.toLowerCase())))},filteredListOptionsMatchAllWords(t){t&&(this.autocompleteValue=t);const e=this.autocompleteValue?.toLowerCase().split(" ");return this.listOptions?.filter((t=>e?.every((e=>t.text.toLowerCase().includes(e)))))},clearAutocompleteValue(){this.autocompleteValue="",this.canShowListOptions=!1},getAutocompleteSuggestions(){const t=(this.$refs?.autocompleteInput).value;t.length>=2?(this.canShowListOptions=!0,this.autocompleteValue=t,this.filteredListOptions?.(t)):this.canShowListOptions=!1},moveToNextDropDownItem(t,e,n){if(void 0!==t.key&&("ArrowDown"==t.key&&(document.getElementById(n+"-suggestion"+(e+1))?(document.getElementById(n+"-suggestion"+(e+1))?.focus(),t.preventDefault()):document.getElementById(n+"-input")?.focus()),"ArrowUp"==t.key&&document.getElementById(n+"-suggestion"+(e-1))&&(document.getElementById(n+"-suggestion"+(e-1))?.focus(),t.preventDefault()),"Escape"===t.key||"Tab"===t.key)){const t=document.getElementById(n+"-dropdown");t&&(t.style.display="none"),document.getElementById(n+"-input")?.focus()}return!1},emitOptionSelected(t,e){window.phoenix.bus?.publish("AUTOCOMPLETE","OPTION_SELECTED",{payload:{text:t,value:e}})}}))),window.Alpine?.data("blade",(()=>({pubChannel:null,pubTopic:null,init(){if(this.$el?.hasAttribute("data-xpr-blade-publish")){const t=this.$el.getAttribute("data-xpr-blade-publish")?.split(":");if(t){const[e,n]=t;this.pubChannel=e,this.pubTopic=n}}},publishEvent(){this.pubChannel&&this.pubTopic&&window.phoenix.bus.publish(this.pubChannel,this.pubTopic)}}))),window.Alpine.data("breadcrumbs",((t,e,n)=>({isDynamic:!1,componentId:"",ariaLabel:"",dynamicContent:[],init(){this.isDynamic=!0===t||"true"===t||!1,this.componentId=e,this.ariaLabel=n,window.phoenix.bus.subscribe("BREADCRUMBS","RENDER",this?.renderDynamicBreadcrumbs.bind(this))},renderDynamicBreadcrumbs(t){t?.payload&&t.payload?.componentId===this.componentId&&(this.dynamicContent=t.payload.items)}}))),window.Alpine.data("broadbandFacts",(()=>({isAnalyticsEnabled:!1,init(){this.isAnalyticsEnabled=this.$el.hasAttribute("data-analytics-broadband-facts")},toggleAccordionForLabel(t){const e=this.$el?.getAttribute("aria-controls"),n=this.$el,i=document.querySelector("[id='"+e+"']"),r=document.querySelectorAll("[id='"+e+"-bbl']");n&&"false"===n.getAttribute("aria-expanded")?(n.setAttribute("aria-expanded","true"),i?.classList.remove("tdds-broadband-facts__details--hide"),r?.forEach((t=>t?.classList.remove("tdds-broadband-facts__details--hide"))),this.isAnalyticsEnabled&&window.phoenix.bus.publish("ANALYTICS","WIDGET",{payload:{widgetName:`Expand Accordion : Broadband Facts-${t}`}})):(n?.setAttribute("aria-expanded","false"),i?.classList.add("tdds-broadband-facts__details--hide"),r?.forEach((t=>t?.classList.add("tdds-broadband-facts__details--hide"))),this.isAnalyticsEnabled&&window.phoenix.bus.publish("ANALYTICS","WIDGET",{payload:{widgetName:`Collapse Accordion : Broadband Facts-${t}`}}))}})));const e="data-a11y-dialog-show",i={appName:"phoenix-experience",className:"IA11yDialogButtonAlpineComponent",methodName:"fetchData"};window.Alpine.data("a11yDialogButton",((t,n)=>({modalXFPath:t,modalVideoID:n,async fetchData(){if(!this.modalXFPath)throw new Error("Path to XF modal is required");let t;try{t=await fetch(`${this.modalXFPath}.content.html`)}catch(t){throw t instanceof Error?new Error(`Unable to connect to ${this.modalXFPath}\n${t.message}`):new Error(`Unable to connect to ${this.modalXFPath}\nUnknown error occurred`)}const n=await t.text(),i=(new DOMParser).parseFromString(n,"text/html").querySelector("[data-xpr-modal]"),r=i?.id;if(!i)throw new Error(`No modals found for ${this.modalXFPath}. Make sure the XF has a modal component.`);document.getElementById(r)||document.getElementById("content-root").appendChild(i),this.$el?.setAttribute(e,r);const a=document.querySelector(`[id="${r}"][x-data="a11yDialog"]`);a&&a.a11yDialogAlpineComponent&&a.a11yDialogAlpineComponent.reset()},init(){if(this.modalXFPath&&(this.modalXFPath.endsWith(".html")&&(this.modalXFPath=this.modalXFPath.replace(/^(.*)\.html$/,"$1")),this.$el&&(this.$el.a11yDialogButtonAlpineComponent=this),this.fetchData().then().catch((()=>{window.phoenix.log.debug(`Error fetching experience fragment in button: ${this.modalXFPath}`,i)}))),this.modalVideoID&&this.$el?.setAttribute(e,this.modalVideoID),"a"===this.$el?.tagName.toLowerCase()&&this.$el?.addEventListener("click",(t=>{t.preventDefault()})),this.$el?.dataset?.xprSubscribeAction){const[t,e,n]=this.$el.dataset.xprSubscribeAction.split(":");window.phoenix.bus.subscribe(t,e,(()=>this.toggleAttribute(n)))}},initPublishOnButton(t,e,n,i){const r={payload:{$el:this.$el,data:i}},a=()=>{window.phoenix.bus.publish(t,e,r)};"init"!==n?this.$el?.addEventListener(n,(()=>a())):a()},toggleAttribute(t){const e=this.$el;e.hasAttribute(t)&&"true"==e.getAttribute(t)?e.removeAttribute(t):e.setAttribute(t,"true")}})));var r=n(2543);window.Alpine.data("overflowContainer",((t,e,n,i,a,o)=>({scrollValue:0,gutterValue:0,gutter:0,isPrevDisabled:!0,isNextDisabled:!1,channel:"",topic:"",init(){if(null==t)throw new Error("Number of cards in container must be provided");this.channel=a||"CARD_CONTAINER",this.topic=o||"RECALIBRATE_SCROLL_POSITION",this.$el&&(this.$el.overflowContainerAlpineComponent=this),this.processScrollInfo(),window.addEventListener("resize",(0,r.debounce)((()=>{this.checkVisibility()}),500)),!0===i&&window.phoenix.bus.subscribe(this.channel,this.topic,this.processScrollInfo.bind(this));const e=this.$refs?.track;new ResizeObserver((()=>{this.processScrollInfo()})).observe(e)},processScrollInfo(){const i=this.$refs?.track;e||(e=0),this.gutterValue="h"===e?.5:e,this.gutter=8*this.gutterValue;const r=i.scrollWidth/t;this.scrollValue=n?n*r+this.gutter:r+this.gutter,this.hideControlsWhenAllContentVisible()},prev(){this.$refs&&(this.$refs.track.scrollLeft-=this.scrollValue)},next(){this.$refs&&(this.$refs.track.scrollLeft+=this.scrollValue)},checkVisibility(){this.hideControlsWhenAllContentVisible()},toggleScroll(){this.$refs&&(this.$refs.track.scrollLeft?this.isPrevDisabled=!1:this.isPrevDisabled=!0,Math.abs(this.$refs.track.scrollLeft)===this.$refs.track.scrollWidth-this.$refs.track.clientWidth?this.isNextDisabled=!0:this.isNextDisabled=!1)},hideControlsWhenAllContentVisible(){if(this.$refs){const t=this.$refs.controls,e=this.$refs.track.scrollWidth-this.$refs.track.clientWidth;t?.setAttribute("aria-hidden",e>0?"false":"true")}}}))),window.Alpine?.data("cardIntent",(()=>({setIntent(t){const e=t.target,n=window.Cookies.withConverter({write:t=>t});let i="";if(e.hasAttribute("data-intent")){switch(e.getAttribute("data-intent")){case"add-a-line":i="ADDALINE";break;case"upgrade":i="UPGRADE"}}""!==i&&n.set("mytmo2tmo",`{"transactionType":"${i}"}`,{domain:".t-mobile.com"}),window.location.href=e.href}}))),window.Alpine?.data("cardPromotion",(t=>({ctaAreHidden:"boolean"==typeof t&&t,linkDetails:{exists:!1,icid:"",analyticsClickLabel:"",target:"_self",href:""},init(){this.ctaAreHidden="boolean"==typeof t&&t;const e=this.$refs?.ctas?.querySelector(".tdds-button");e&&(this.linkDetails.exists=this.ctaAreHidden,this.linkDetails.icid=e.getAttribute("data-icid")??"",this.linkDetails.analyticsClickLabel=e.getAttribute("data-analytics-click")??"",this.linkDetails.target=e.getAttribute("target")??"",this.linkDetails.href=e.getAttribute("href")??"")}}))),window.Alpine.data("dynamicTextWrapper",((t,e)=>({channel:"DYNAMIC_TEXT",topic:"FETCH_SUCCESS",dynamicText:{},init(){this.channel=t||"DYNAMIC_TEXT",this.topic=e||"FETCH_SUCCESS",window.phoenix.bus.subscribe(this.channel,this.topic,this.renderText.bind(this))},renderText(t){if(t?.payload)for(const e in t.payload)if(Object.prototype.hasOwnProperty.call(t.payload,e))if(this.$el?.classList.remove("phx-skeleton-loader"),Array.isArray(t.payload[e])){const n=t.payload[e];this.renderList(n,e)}else this.dynamicText[e]=t.payload[e]??""},renderList(t,e){const n=document.createElement("ul");t.forEach((t=>{const e=document.createElement("li");e.textContent=t,n.append(e)})),this.dynamicText[e]=n.outerHTML}}))),window.Alpine.data("featureList",((t,e)=>({channel:t||"FEATURELIST",topic:e||"FETCH_FEATURELIST_ITEMS_SUCCESS",init(){window.phoenix.bus.subscribe(this.channel,this.topic,this.processListItems?.bind(this))},processListItems(t){for(const e in t?.payload){const e=t?.payload;e&&e.length>0&&e.forEach((t=>{document.getElementById(t)?.classList.add("phx-featureList__item--visually-disabled"),document.getElementById(t)?.classList.remove("phx-featureList__excerpt--visually-hidden")}))}this.$el.getElementsByClassName("phx-skeleton-loader-feature-list")?.item(0)?.classList.remove("phx-skeleton-loader-feature-list")}})));const a=t=>{if(!t)return"";return t.map((t=>{let e,n="primary";const i="newTab"===t.webAction?"target='_blank'":"",r=t.payload?t.payload:"",a=t.channel&&t.topic?`x-init="initPublishOnButton('${t.channel}', '${t.topic}', 'click', '${r}')" x-data="a11yDialogButton"`:"";switch(t.style){case"digx:headless/button/primary":case"primary":n="primary";break;case"digx:headless/button/secondary":case"secondary":n="secondary";break;case"digx:headless/button/tertiary":case"tertiary":n="tertiary"}if("event"===t.webAction)e=``;else e=`${t.name}`;return e})).join("")},o="main-content-wrapper";window.Alpine.data("fullPageError",(()=>({dynamicContent:null,init(){window.phoenix.bus.publish("SHOW_HIDE","TOGGLE",{payload:{show:[o]}}),window.phoenix.bus.subscribe("FULL_PAGE","SHOW_ERROR_CONTENT",this.renderContent?.bind(this))},renderContent(t){this.dynamicContent={...t?.payload,footer:a(t?.payload?.ctas)},window.phoenix.bus.publish("SHOW_HIDE","TOGGLE",{payload:{hide:[o]}}),this.$nextTick?.((()=>{this.$el?.querySelector("[data-xpr-error-title]")?.focus()}))}})));const s="(min-width: 1024px)",u="(max-width: 599px)",l="(max-width: 1023px)";window.Alpine.data("headline",(t=>({headlineText:t,init(){window.phoenix.experience.utils?.registerMediaQuerySensor?.({max:l,action:t=>{if(t){this.$el?.setAttribute("aria-hidden","true");const t=document.createElement("h1");t.setAttribute("style","font-size:0;"),t.setAttribute("data-xpr-hidden-h1","hidden-h1"),t.innerHTML=this.headlineText,document.querySelector("#content-main")?.prepend(t)}else document.querySelector("[data-xpr-hidden-h1]")?.remove(),this.$el?.removeAttribute("aria-hidden")}})}}))),function(t){window.CMP=window.CMP||{},window.CMP.image=window.CMP.image||{},window.CMP.image.v3=function(){var e="image",n="[data-cmp-hook-image='imageV3']",i={widths:{default:[],transform:function(t){var e=[];return t.split(",").forEach((function(t){t=parseFloat(t),isNaN(t)||e.push(t)})),e}},dmimage:{default:!1,transform:function(t){return!(null==t)}},src:{transform:function(t){return decodeURIComponent(t)}},smartcroprendition:""};function r(t){var n=this;n.initImage=function(t){var r=CMP.utils.readData(t,e);n._properties=CMP.utils.setupProperties(r,i),n._properties.dmimage&&CMP.image.dynamicMedia.setDMAttributes(t,n._properties)},n.initImage(t.element)}return{init:function(){for(var i=t.querySelectorAll(n),a=0;a0&&i.forEach((function(t){t.querySelectorAll&&[].slice.call(t.querySelectorAll(n)).forEach((function(t){new r({element:t,options:CMP.utils.readData(t,e)})}))}))}))})).observe(s,{subtree:!0,childList:!0,characterData:!0})}}}();var e="loading"!==t.readyState?Promise.resolve():new Promise((function(e){t.addEventListener("DOMContentLoaded",e)}));Promise.all([e]).then(window.CMP.image.v3.init)}(window.document),function(t){window.CMP=window.CMP||{},window.CMP.image=window.CMP.image||{},window.CMP.image.dynamicMedia=function(){var t={},e="{.width}",n=window.devicePixelRatio||1,i=20,r=function(n){var i=new XMLHttpRequest,r=n.split(e)[0]+"?req=set,json";return i.open("GET",r,!1),i.onload=function(){if(i.status>=200&&i.status<400){var e,n=i.responseText,r=new RegExp(/^(?:\/\*jsonp\*\/)?\s*([^()]+)\(([\s\S]+),\s*"[0-9]*"\);?$/gim),a=new RegExp(/^{[\s\S]*}$/gim),o=r.exec(n);if(o){var s=o[2];a.test(s)&&(e=JSON.parse(s))}if(e&&e.set.relation&&e.set.relation.length>0)for(var u=0;u0)for(var a in r=[],t)r.push(n.replace(e,i[a])+" "+a+"w");return r.join(",")},getSrc:function(t,n){return t.indexOf(e)>-1&&(t=t.replace(e,n)),t},setDMAttributes:function(t,e){var i=e.src.replace("dpr=off","dpr=on,{dpr}");i=i.replace("{dpr}",n);var s,u={};if("SmartCrop:Auto"===e.smartcroprendition&&(u=r(i)),e.widths&&e.widths.length>0||Object.keys(u).length>0){var l=t.querySelector("img"),c=o(t,t.parentNode);"SmartCrop:Auto"===e.smartcroprendition?(l.setAttribute("srcset",CMP.image.dynamicMedia.getSrcSet(i,u)),s=a(Object.keys(u,c)),l.setAttribute("src",CMP.image.dynamicMedia.getSrc(i,u[s]))):(s=a(e.widths,c),l.setAttribute("src",CMP.image.dynamicMedia.getSrc(i,s)))}},getWidth:o}}(),t.dispatchEvent(new CustomEvent("core.wcm.components.commons.site.image.dynamic-media.loaded"))}(window.document),window.document,window.CMP=window.CMP||{},window.CMP.utils={readData:function(t,e){var n=t.dataset,i=[],r=e,a=["is","hook"+(r=r.charAt(0).toUpperCase()+r.slice(1))];for(var o in n)if(Object.prototype.hasOwnProperty.call(n,o)){var s=n[o];0===o.indexOf("cmp")&&(o=(o=o.slice(3)).charAt(0).toLowerCase()+o.substring(1),-1===a.indexOf(o)&&(i[o]=s))}return i},setupProperties:function(t,e){var n={};for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var r=e[i];t&&null!=t[i]?r&&"function"==typeof r.transform?n[i]=r.transform(t[i]):n[i]=t[i]:n[i]=e[i].default}return n}},window.Alpine.data("inlineError",(t=>({hasContent:!1,topic:t,init(){this.topic?this.topic:this.topic="SHOW",window.phoenix.bus.subscribe("INLINE_ERROR",this.topic,this.getContentFragment.bind(this)),window.phoenix.bus.subscribe("ERROR",this.topic,this.handleInlineError.bind(this))},handleInlineError(t){const e=t?.payload?.message;e&&(this.message=e,this.hasContent=!0)},getContentFragment(t){const e=t?.payload?.content;"string"!=typeof e&&window.phoenix.bus.publish("ERROR","CONTENT_FRAGMENT",{payload:{topic:this.topic,error:{content:{notificationCode:e?.notificationCode,namespace:e?.namespace}}}})}}))),window.Alpine.data("list",((t,e)=>({dynamicList:[],channel:t||"LIST",topic:e||"RENDER_CONTENT",init(){window.phoenix.bus.subscribe(this.channel,this.topic,this.renderContent.bind(this))},renderContent(t){this.dynamicList=t?.payload??[]}}))),window.Alpine.data("logoGrid",(()=>({showMoreButton:null,logoGrid:null,init(){this.showMoreButton=this.$el?.querySelector("[data-xpr-logoGrid-btn]"),this.logoGrid=this.$el?.querySelector("[data-xpr-logoGrid]")},showAllIcons(){this.logoGrid?.classList.remove("xpr-extraHidden"),this.showMoreButton&&(this.showMoreButton.style.display="none")}}))),window.Alpine.data("menu",((t,e)=>({componentId:null,isOpen:null,selectedItems:null,menuTrigger:null,menuList:null,menuListItems:null,menuListLength:null,currentMenuItem:null,currentMenuItemIndex:null,previousMenuItemIndex:null,nextMenuItemIndex:null,firstMenuListItem:null,lastMenuListItem:null,firstChars:[],menuItemCallback:null,init(){this.componentId=t,this.isOpen=!1,this.selectedItems=new Set,this.menuTrigger=this.$refs?.["menu-trigger"],this.menuList=this.$refs?.["menu-list"],this.menuList&&(this.menuListItems=Array.from(this.menuList.querySelectorAll("li")),this.menuListLength=this.menuListItems.length,this.firstMenuListItem=this.menuListItems[0],this.lastMenuListItem=this.menuListItems[this.menuListItems.length-1],this.menuListItems.forEach((t=>{t.tabIndex=-1,this.firstChars?.push(t?.textContent?.trim()[0].toLowerCase()),t.addEventListener("click",this.onMenuItemClick.bind(this)),t.addEventListener("mouseover",this.onMenuItemMouseOver.bind(this)),"true"===t.getAttribute("aria-checked")&&this.selectedItems?.add(t.id)}))),this.menuTrigger.addEventListener("keydown",this.onMenuTriggerKeyDown.bind(this)),this.menuTrigger.addEventListener("click",this.onMenuTriggerClick.bind(this)),this.menuList.addEventListener("keydown",this.onMenuKeyDown.bind(this)),this.$el?.addEventListener("focusin",this.onFocusIn.bind(this)),this.$el?.addEventListener("focusout",this.onFocusOut.bind(this)),window.addEventListener("mousedown",this.onBackgroundMouseDown.bind(this),!0),this.menuItemCallback=e},openMenu(){this.menuTrigger&&this.menuList&&(this.menuTrigger.setAttribute("aria-expanded","true"),this.menuList.style.display="block",this.menuList.focus(),this.setFocusToFirstMenuItem(),this.isOpen=!0)},closeMenu(){this.menuTrigger&&this.menuList&&(this.menuTrigger.setAttribute("aria-expanded","false"),this.menuList.setAttribute("aria-activedescendant",""),this.menuList.style.display="none",this.menuListItems?.forEach((t=>{t.classList.remove("focus")})),this.menuTrigger.focus(),this.isOpen=!1)},setFocusToFirstMenuItem(){this.firstMenuListItem&&this.setFocusToMenuItem(this.firstMenuListItem)},setFocusToLastMenuItem(){this.lastMenuListItem&&this.setFocusToMenuItem(this.lastMenuListItem)},setFocusToMenuItem(t){this.menuListItems?.forEach(((e,n)=>{e===t?(this.currentMenuItem=t,this.updateIndexes(n),e.classList.add("force-focus"),this.menuList?.setAttribute("aria-activedescendant",e.id)):e.classList?.remove("force-focus")}))},updateIndexes(t){this.currentMenuItemIndex=t,this.menuListItems&&this.menuListLength&&(this.previousMenuItemIndex=0==t?this.menuListLength-1:t-1,this.nextMenuItemIndex=t!=this.menuListItems.length-1?t+1:0)},setFocusToPreviousMenuitem(){if(this.menuListItems){const t=this.menuListItems[this.previousMenuItemIndex];this.setFocusToMenuItem(t)}},setFocusToNextMenuitem(){if(this.menuListItems){const t=this.menuListItems[this.nextMenuItemIndex];this.setFocusToMenuItem(t)}},setFocusByFirstCharacter(t){let e,n;t=t.toLowerCase(),this.menuListItems&&(e=this.currentMenuItemIndex,e>=this.menuListItems.length&&(e=0)),n=this.firstChars?.indexOf(t,e),-1===n&&(n=this.firstChars?.indexOf(t,0)),null!=n&&n>-1&&this.menuListItems&&this.setFocusToMenuItem(this.menuListItems[n])},onFocusIn(){this.$el?.classList.add("focus")},onFocusOut(){this.$el?.classList.remove("focus")},onMenuTriggerKeyDown(t){let e=!1;switch(t.key){case" ":case"Enter":case"ArrowDown":case"Down":this.openMenu(),this.setFocusToFirstMenuItem(),e=!0;break;case"Esc":case"Escape":this.closeMenu(),e=!0;break;case"Up":case"ArrowUp":this.openMenu(),this.setFocusToLastMenuItem(),e=!0}e&&(t.stopPropagation(),t.preventDefault())},onMenuTriggerClick(t){this.isOpen?this.closeMenu():this.openMenu(),t.stopPropagation(),t.preventDefault()},onMenuKeyDown(t){const e=t.key;let n=!1;function i(t){return 1===t.length&&t.match(/\S/)}if(!(t.ctrlKey||t.altKey||t.metaKey)){if(t.shiftKey)i(e)&&(this.setFocusByFirstCharacter(e),n=!0),"Tab"===t.key&&(this.closeMenu(),n=!0);else switch(e){case" ":case"Enter":this.performMenuAction(t),n=!0;break;case"Esc":case"Escape":this.closeMenu(),n=!0;break;case"Up":case"ArrowUp":this.setFocusToPreviousMenuitem(),n=!0;break;case"ArrowDown":case"Down":this.setFocusToNextMenuitem(),n=!0;break;case"Home":case"PageUp":this.setFocusToFirstMenuItem(),n=!0;break;case"End":case"PageDown":this.setFocusToLastMenuItem(),n=!0;break;case"Tab":this.closeMenu();break;default:i(e)&&(this.setFocusByFirstCharacter(e),n=!0)}n&&(t.stopPropagation(),t.preventDefault())}},onMenuItemMouseOver(t){const e=t.currentTarget;this.setFocusToMenuItem(e)},onMenuItemClick(t){this.currentMenuItem=t.currentTarget,this.performMenuAction(t)},onBackgroundMouseDown(t){this.$el?.contains(t.target)||this.isOpen&&this.closeMenu()},performMenuAction(t){if("true"!==this.currentMenuItem?.getAttribute("aria-disabled"))switch(this.currentMenuItem?.getAttribute("role")){case"menuitemcheckbox":return void this.menuItemCheckboxAction(t);case"menuitemradio":return void this.menuItemRadioAction(t);case"menuitem":this.menuItemAction(t);break;default:this.closeMenu()}},menuItemCheckboxAction(t){const e=this.currentMenuItem?.getAttribute("aria-checked");this.currentMenuItem?.setAttribute("aria-checked","true"===e?"false":"true"),this.selectedItems&&this.currentMenuItem&&("true"==e?this.selectedItems.delete(this.currentMenuItem.id):this.selectedItems.add(this.currentMenuItem.id)),this.menuItemCallback?.(t,{selected:[...this.selectedItems]})},menuItemRadioAction(t){this.menuListItems?.forEach((t=>{this.currentMenuItem===t?t.setAttribute("aria-checked","true"):t.setAttribute("aria-checked","false")})),this.selectedItems?.clear(),this.selectedItems?.add(this.currentMenuItem?.id),this.menuItemCallback?.(t,{selected:[this.selectedItems]}),this.closeMenu()},menuItemAction(t){this.selectedItems?.clear(),this.selectedItems?.add(this.currentMenuItem?.id),this.menuItemCallback?.(t,{selected:[this.currentMenuItem?.id]}),this.closeMenu()}})));const c=async t=>{let e=!1;return(await fetch(t,{method:"HEAD"})).ok&&(e=!0),e},d=(t,e,n)=>{const i=document.createElement("iframe");i.setAttribute("frameborder","0"),i.setAttribute("allowfullscreen",""),i.setAttribute("allow","autoplay; fullscreen"),i.setAttribute("src",t),i.setAttribute("title",n),e.appendChild(i),i.focus()},h=async(t,e,n)=>{const i=document.createElement("video"),r=await(async t=>{const e=[],n=t.substring(0,t.lastIndexOf(".")),i={en:{label:"English",kind:"subtitles"},es:{label:"Español",kind:"subtitles"}};for(const[t,r]of Object.entries(i)){const i=`${n}-${t}.vtt`;await c(i)&&e.push({label:r.label,kind:r.kind,srclang:t,src:i})}return e})(t);i.setAttribute("autoplay","true"),i.setAttribute("controls","true"),i.setAttribute("src",t),i.setAttribute("type","video/mp4"),i.setAttribute("title",n),r.forEach((t=>{i.append((t=>{const{src:e,label:n,kind:i,srclang:r}=t,a=document.createElement("track");return a.setAttribute("label",n),a.setAttribute("kind",i),a.setAttribute("srclang",r),a.setAttribute("src",e),a})(t))})),e.appendChild(i),i.focus()},p=async(t,e)=>{let n;switch(e.type){case"youtube":n=`https://www.youtube.com/embed/${e.id}?rel=${e.youtube?.disableSuggestedVideo}&showinfo=0&autoplay=1&enablejsapi=1&start=${e.youtube?.timeStamp}`,d(n,t,e.title);break;case"vimeo":n=`https://player.vimeo.com/video/${e.id}?autoplay=1&loop=0&autopause=0`,d(n,t,e.title);break;case"asset":await h(e.source,t,e.title)}},f=(t,e)=>{const n=new window.s7viewers.VideoViewer(t);n.setHandlers({initComplete:()=>{let i=!1;window.phoenix.bus.publish("VIDEO","DYNAMIC_MEDIA_PLAYER_INITIALIZED",{payload:{playerId:t.containerId}});const r=n.getComponent("videoPlayer");n.getComponent("mutableVolume").setPosition(0),r.addEventListener(window.s7sdk.event.VideoEvent.NOTF_CURRENT_TIME,(()=>{r.getCurrentTime()>0&&!i&&(n.getComponent("mutableVolume").setPosition(1),i=!0)})),r.addEventListener(window.s7sdk.event.VideoEvent.NOTF_VIDEO_END,(()=>{e.querySelector(".s7playpausebutton").focus()}))}}),n.init()},m=t=>{let e=!1;const n=t?.getAttribute("data-xpr-media-viewer-script");if(!n)return!1;if((t=>{const e=document.head.querySelectorAll("script");let n=0;for(let i=0;i{e=!0,window.phoenix.bus.publish("VIDEO","DYNAMIC_MEDIA_PLAYER_SCRIPT_LOADED")}))}return e},y=t=>{let e=!1,n={type:"",title:"",id:"",source:"",youtube:{timeStamp:"",disableSuggestedVideo:""},dynamicMedia:{containerId:"",params:{}}};e="dynamicMedia"===t?.getAttribute("data-xpr-video-type");const i=t?.getAttribute("data-xpr-video-dm-view-modifiers"),r=(t=>{if(t){const e={};return t.split("&").forEach((t=>{const n=t.indexOf("=");if(n>0){const i=t.substring(0,n),r=t.substring(n+1);e[i]=r}})),e}return{}})(i),a={asset:t?.getAttribute("data-xpr-video-dm-asset"),caption:t?.getAttribute("data-xpr-video-dm-caption"),serverUrl:t?.getAttribute("data-xpr-video-dm-serverimage-url"),videoServerUrl:t?.getAttribute("data-xpr-video-dm-servervideo-url"),...r};return n={...{type:t?.getAttribute("data-xpr-video-type")??"",title:t?.getAttribute("data-xpr-video-title")??"",id:t?.getAttribute("data-xpr-video-id")??"",source:t?.getAttribute("data-xpr-video-src")??"",youtube:{timeStamp:t?.getAttribute("data-xpr-video-youtube-timestamp"),disableSuggestedVideo:t?.getAttribute("data-xpr-video-youtube-rel")}},dynamicMedia:{containerId:t?.id,params:a}},{playerReferences:n,isDynamicMediaVideo:e}};window.Alpine.data("a11yDialog",(()=>({$el:void 0,config:{customChannelTopic:!1,useDynamicContent:!1,authoredAriaLabel:""},dialog:{},dialogContent:void 0,defaultComponentTitle:null,defaultAriaLabel:null,dynamicContent:{analyticsTitle:null,ariaLabel:null,eyebrow:null,title:null,content:null,footer:null},modalContent:{analyticsTitle:"",ariaLabel:"",eyebrow:"",title:"",content:"",ctas:[],footer:""},showBackButton:!1,video:{},isVideoDynamicallyCreated:!1,isBackButtonEnabled:!1,isDynamicMediaVideo:!1,hasDynamicMediaScriptLoaded:!1,reset(){this.dialog?.destroy(),this.init()},init(){this.$el.a11yDialogAlpineComponent=this,this.dialog=new window.A11yDialog(this.$el),this.dialogContent=this.$el.querySelector("[data-xpr-modal-dialog]");const t=this.$el?.dataset;this.config=JSON.parse(t.xprConfig??"{}"),this.defaultAriaLabel=this.config.authoredAriaLabel,this.defaultComponentTitle=this.$el.getAttribute("data-modal-name"),this.isBackButtonEnabled=this.$el.querySelector("[data-xpr-modal-back-button]")?.getAttribute("data-xpr-modal-back-button");const e=this.config?.customChannelTopic,n=this.config.useDynamicContent,i=this.config.pubChannel,r=this.config.pubTopic||"FETCH_MODAL_CONTENT_SUCCESS",a={payload:{dialog:{$el:this.$el}}};this.$el.focus(),this.events(),this.video=this.$el.querySelector("[data-xpr-video]"),this.hasDynamicMediaScriptLoaded=m(this.video),this.dialog.on("show",(async()=>{this.buildVideo(),this.dialogContent&&this.dialogContent.scrollTo(0,0),window.phoenix.bus.publish("MODAL","SHOW",a),window.bodyScrollLock.disableBodyScroll(this.$el,{allowTouchMove:()=>!0})})),this.dialog.on("hide",(()=>{const t=this.$el.querySelector("[data-xpr-video]");t&&(t.innerHTML=""),window.phoenix.bus.publish("MODAL","HIDE",{}),window.bodyScrollLock.enableBodyScroll(this.$el)})),(e||n)&&window.phoenix.bus?.subscribe(i,r,(t=>{n&&this.renderContent(t),this.dialog?.show()}))},emitGoBack(){window.phoenix.bus.publish("MODAL","BACK_BUTTON_CLICK")},events(){window.phoenix.bus?.subscribe("MODAL","CLOSE",(()=>{this.dialog?.hide()})),this.isBackButtonEnabled&&(window.phoenix.bus.subscribe("MODAL","BACK_BUTTON_SHOW",(()=>{this.showBackButton=!0})),window.phoenix.bus.subscribe("MODAL","BACK_BUTTON_HIDE",(()=>{this.showBackButton=!1}))),window.phoenix.bus?.subscribe("MODAL","OPEN_BY_ID",(t=>{const e=t;this.$el.id===e.payload?.componentId&&this.dialog?.show()})),window.phoenix.bus.subscribe("VIDEO","DYNAMIC_MEDIA_PLAYER_SCRIPT_LOADED",(()=>{this.hasDynamicMediaScriptLoaded=!0})),window.phoenix.bus.subscribe("VIDEO","DYNAMIC_MEDIA_PLAYER_INITIALIZED",(()=>{const t=this.$el.querySelector("[data-xpr-dynamic-media-container]"),e=t?.querySelector(".s7playpausebutton");this.$focus?.focus(e)}))},renderContent(t){this.dynamicContent={...t?.payload,footer:t?.payload?.ctas?a(t.payload?.ctas):t?.payload?.footer},this.$el.setAttribute("aria-label",t?.payload?.ariaLabel??this.defaultAriaLabel),this.$el.setAttribute("data-analytics-component-title",t?.payload?.analyticsTitle??this.defaultComponentTitle)},async buildVideo(){this.isVideoDynamicallyCreated=this.video?.hasAttribute("data-xpr-video-is-created")??!1;const{playerReferences:t,isDynamicMediaVideo:e}=y(this.video);if(this.video&&this.isVideoDynamicallyCreated){if(!e){await p(this.video,t);const e=this.$el.querySelector("[data-xpr-modal-video-hide]"),n=this.$el.querySelector("[data-xpr-modal-video-focus]");this.$el.addEventListener("keyup",(t=>{9!==t.keyCode||t.shiftKey||document.activeElement===n&&e.focus()}))}e&&this.hasDynamicMediaScriptLoaded&&f(t.dynamicMedia,this.video)}}}))),window.Alpine.data("notificationBanner",(t=>({showBanner:!0,isSoftAlert:!1,bannerId:"",options:t,init(){this.bannerId=this.$el?.id,this.showBanner=!(this.options.enableSoftAlert&&this.getSessionState())},dismiss(){this.options.enableSoftAlert&&(this.setSessionState(),this.removeBanner())},getSessionState(){return window.sessionStorage.getItem(this.bannerId)},setSessionState(){window.sessionStorage.setItem(this.bannerId,"true")},removeBanner(){this.$el?.closest(`#${this.bannerId}`)?.remove()}})));function b(t){t.offset=t.offset||0;const e=parseInt(document.documentElement.style.getPropertyValue("--js--header-height-overall")||"0px"),n=function(t){const e=t?.getBoundingClientRect(),n=document.body,i=document.documentElement,r=window.pageYOffset||i.scrollTop||n.scrollTop,a=i.clientTop||n.clientTop||0,o=e?.top+r-a;return Math.round(o)}(t.scrollToElement)-e-t.offset;window.scrollTo({top:n,behavior:"smooth"})}window.Alpine.data("progressIndicator",((t,e,n)=>({currentLabel:null,stepMax:null,currentStep:null,dynamicLabels:{selectElementAriaLabel:null,ariaLabel:null,leadingText:null,supportText:null,titleText:null,infoWarning:null},authoredLabels:{selectElementAriaLabel:null,ariaLabel:null,leadingText:null,supportText:null,titleText:null,infoWarning:null},init(){this.currentLabel=t,this.currentStep=e,this.stepMax=n,this.authoredLabels=JSON.parse(this.$el?.dataset.xprAuthoredLabels??"{}"),this.replaceAuthoredTemplates?.()},replaceAuthoredTemplates(){if(!this.dynamicLabels)return;const t=this.currentStep?.toString()??"",e=this.currentLabel??"",n=this.stepMax?.toString()??"";this.replaceTemplate&&(this.dynamicLabels.selectElementAriaLabel=this.replaceTemplate(this.authoredLabels?.selectElementAriaLabel,t,e,n),this.dynamicLabels.ariaLabel=this.replaceTemplate(this.authoredLabels?.ariaLabel,t,e,n),this.dynamicLabels.leadingText=this.replaceTemplate(this.authoredLabels?.leadingText,t,e,n),this.dynamicLabels.supportText=this.replaceTemplate(this.authoredLabels?.supportText,t,e,n),this.dynamicLabels.titleText=this.replaceTemplate(this.authoredLabels?.titleText,t,e,n),this.dynamicLabels.infoWarning=this.replaceTemplate(this.authoredLabels?.infoWarning,t,e,n))},replaceTemplate(t,e,n,i){return t?t.replace("{{currentStep}}",e).replace("{{currentLabel}}",n).replace("{{stepMax}}",i):null},handleStepChange(t){const e=t.target,n=e.options[e.selectedIndex],i=n.getAttribute("data-xpr-progressindicator-steplink"),r=n.hasAttribute("data-xpr-progressindicator-steplinknewtab"),a=window.location.protocol+"//"+window.location.host+i+location.search;i!==window.location.pathname&&(r?window.open(a):window.location.assign(a))}}))),window.Alpine.data("quickLinks",(()=>({quickLinks:[],menuEl:null,listEl:null,trackEl:null,component:null,hasAnalytics:null,headline:void 0,isMenuOpen:!1,isMobile:!1,isExpanded:!0,init(){this.component=this.$el,this.menuEl=this.$el?.querySelector("[data-xpr-quicklinks-menu]"),this.listEl=this.$el?.querySelector("[data-xpr-quicklinks-group]"),this.trackEl=this.$el?.querySelector(".xpr-quickLinks__track"),this.hasAnalytics=this.$el?.getAttribute("data-analytics-quicklinks");const t=this.$el?.querySelectorAll("[data-xpr-quicklinks]");this.totalLinks=t?.length;const e=this.$el?.querySelector("[data-xpr-quicklinks-current]"),n={el:e?.getAttribute("data-xpr-quicklinks"),list:e?.querySelector("[data-xpr-quicklinks-list]"),toggle:e?.querySelector("[data-xpr-quicklinks-toggle]")};this.populateLinks(n),this.observeActiveAnchorLink(),window.phoenix.experience.utils.registerMediaQuerySensor({max:l,action:t=>this.isMobile=t})},populateLinks(t){const e=document.querySelectorAll("[data-xpr-anchor]");e.length?e.forEach((e=>{const n=this.generateListItem(e);t.list.insertAdjacentHTML("beforeend",n)})):(t.toggle?.setAttribute("aria-hidden","true"),t.list?.setAttribute("aria-hidden","true"))},generateListItem(t){const e=t?.getAttribute("data-xpr-anchor"),n=t?.getAttribute("data-anchor-href"),i=t?.getAttribute("id");let r="";this.hasAnalytics&&(r=`data-analytics-quicklinks-sub-item="${e}"`);return`\n
  • \n ${e}\n
  • `},setActiveAnchor(t){const e=(t,e)=>{return[].map.call(e,(function(t){return t})).sort((n=t,function(t,e){const i=parseInt(t.style[n]),r=parseInt(e.style[n]);return Math.sign(i-r)}));var n},n=()=>{document.querySelectorAll("[data-xpr-quicklinks-anchor]").forEach((t=>{t.classList.remove("xpr-quickLinks__subLink--active")}))},i=t=>{const e=t.closest(".xpr-layoutMain__container"),n=e?.querySelector("[data-xpr-quicklinks-list]"),i=t.getAttribute("id"),r=n?.querySelector(`[data-xpr-quicklinks-anchor='${i}']`);r?.classList.add("xpr-quickLinks__subLink--active")},r=document.querySelectorAll("[data-xpr-anchor]");e("top",r).forEach(((t,e)=>{t.setAttribute("data-anchor-index",e.toString())}));let a=-1;t.forEach((t=>{const r=(t=>t.rootBounds?.bottom-t.boundingClientRect.bottom>t.rootBounds?.bottom/2)(t);t.intersectionRatio>0&&t.isIntersecting?t.target.setAttribute("data-anchor-intersecting","true"):r||!1!==t.isIntersecting?t.target.removeAttribute("data-anchor-intersecting"):(t.target.removeAttribute("data-anchor-intersecting"),a=parseInt(t.target.getAttribute("data-anchor-index")));const o=document.querySelectorAll("[data-anchor-intersecting]");if(0==o.length&&a>0){n();const t=a-1,e=document.querySelector(`[data-anchor-index='${t}']`);i(e)}else if(1==o.length)n(),i(o[0]);else if(o.length>1){n();const t=e("top",o);i(t[0])}}))},observeActiveAnchorLink(){const t=document.querySelectorAll("[data-xpr-anchor]"),e={threshold:[0,1],rootMargin:`-${document.documentElement.style.getPropertyValue("--js--header-height-overall")||"0px"} 0% -25% 0%`},n=new IntersectionObserver(this.setActiveAnchor,e);t&&t.forEach((t=>{n.observe(t)}))},handleMenu(t){this.isMenuOpen="open"===t,this.menuEl?.setAttribute("aria-expanded",`${this.isMenuOpen}`),this.component?.classList.toggle("xpr-quickLinks__main--open",this.isMenuOpen),this.isMobile&&("open"===t?window.bodyScrollLock.disableBodyScroll(this.trackEl):window.bodyScrollLock.enableBodyScroll(this.trackEl),document.documentElement.style.overflow="open"===t?"hidden":"auto")},handleSubLinkClick(t){this.isMobile&&this.handleMenu("close"),this.target=t.target,this.headline=document.querySelector(`[data-anchor-href='${this.target.hash}']`),this.id=this.target.hash.slice(1),setTimeout((()=>{b({scrollToElement:this.headline,offset:this.isMobile?60:16})}),20)}}))),window.Alpine.data("runtimeNotificationAction",(t=>({ariaLabel:"",content:"",actionType:"NAVIGATION",init(){this.ariaLabel=t.ariaLabel,this.content=t.content},getActionType(){return t?.type},getNavigationLink(){return t?.location},executePubSubEvent(){window.phoenix.bus.publish(t.channel,t.topic,t.datagram)}}))),window.Alpine.data("runtimeNotificationArea",(()=>({notificationAreaName:"",notifications:[],init(){this.notificationAreaName=this.$el?.getAttribute("data-notification-area-name");const t=window.phoenix.bus.subscribe("RUNTIME_NOTIFICATION","SHOW",this.showNotification.bind(this)),e=window.phoenix.bus.subscribe("RUNTIME_NOTIFICATION","HIDE",this.hideNotification.bind(this));this.destroy=()=>{t(),e()}},hideNotification(t){if(this.notificationAreaName.trim().toLowerCase()===t?.payload?.notificationAreaName?.trim().toLowerCase()||!t?.payload?.notificationAreaName&&"global"===this.notificationAreaName.trim().toLowerCase())if(t?.payload?.notificationId){const e=this.notifications.findIndex((e=>e.id===t?.payload?.notificationId));e>-1&&this.notifications.splice(e,1)}else this.notifications=[]},showNotification(t){t&&(this.notificationAreaName.trim().toLowerCase()===t?.payload?.notificationAreaName?.trim().toLowerCase()||!t?.payload?.notificationAreaName&&"global"===this.notificationAreaName.trim().toLowerCase())&&this.notifications.push(t)}})));const g={appName:"phoenix-experience",className:"runtimeNotification"};window.Alpine.data("runtimeNotification",(t=>({isInverse:!1,hideIcon:!1,disableClose:!1,hasContent:!1,title:"",content:"",actions:[],async init(){this.isInverse=t?.payload?.isInverse||!1,this.hideIcon=t?.payload?.hideIcon,this.disableClose=t?.payload?.disableClose,this.actions=t?.payload?.actions||[],this.title=t?.payload?.title||"",this.content=await this.loadContent(),this.content&&this.content.trim().length>0&&(this.hasContent=!0),"number"==typeof t?.payload?.autoClose&&setTimeout(this.closeNotification.bind(this),1e3*t?.payload?.autoClose),window.phoenix.bus.publish("RUNTIME_NOTIFICATION","SHOWN",{payload:{type:t?.payload?.type??"INFO",alert:t?.payload?.alert,content:this.content,analyticsOverride:t?.payload?.analyticsOverride}})},getType(){let e;const n=t?.payload?.type?.toLowerCase()||"announcement";switch(n){case"info":e="announcement";break;case"warning":e="caution";break;default:e=n}return e},cssClassGrid(){return t?.payload?.disableClose?"":" tdds-notice-bar--grid"},async loadContent(){if("string"==typeof t?.payload?.content)return t?.payload?.content;{let e="/self-service-content/runtimeNotification";t?.payload?.content?.notificationCode&&(e+=`.notificationCode_${t?.payload?.content?.notificationCode}`),t?.payload?.content?.namespace&&(e+=`.namespace_${(t?.payload?.content).namespace}`);try{const t=await fetch(`${e}.json`,{method:"GET",headers:{Accept:"application/json","Content-Type":"application/json"}});if(!t.ok)return window.phoenix.log.error("Could not retrieve notification content fragment.",g),"";const n=await t.json();return n.message&&0!==n.message.trim().length?n.message:(window.phoenix.log.error("Notification content fragment is empty.",g),"")}catch(t){return window.phoenix.log.error("Could not retrieve notification content fragment.",g,{exception:t}),""}}},closeNotification(){window.phoenix.bus.publish("RUNTIME_NOTIFICATION","HIDE",{payload:{notificationId:t.id}})}})));class v{shortcutsElement;listWrapper;isAnchorsList;constructor(t){this.shortcutsElement=t,this.listWrapper=this.shortcutsElement?.querySelector("[data-xpr-shortcuts-list]"),this.isAnchorsList="true"===this.listWrapper?.getAttribute("data-xpr-shortcuts-anchors"),this.isAnchorsList&&this.attachAnchorsList()}attachAnchorsList(){const t=[],e=this.shortcutsElement?.querySelectorAll("[data-xpr-shortcuts-anchor-target]");e.forEach((e=>{const n=e?.getAttribute("data-xpr-shortcuts-anchor-target");n&&t.push(n)})),this.attachIntersectionObserver(t),this.attachScrollToArea(e)}attachIntersectionObserver(t){let e=0;const n=parseInt(document.documentElement.style.getPropertyValue("--js--header-height-overall")||"0px"),i=parseInt(document.documentElement.style.getPropertyValue("--js--header-height-primary")||"0px"),r=this.listWrapper?.clientHeight||0;window.phoenix?.experience?.utils?.registerMediaQuerySensor?.({min:s,action:t=>e=t?i:n});const a=e+r,o=-1*a,u=-1*(window.innerHeight-a),l=new IntersectionObserver((function(t){t.forEach((t=>{const e=document.querySelector(`[data-xpr-shortcuts-anchor-target="${t.target.id}"]`);e&&(t.isIntersecting||e.classList.remove("phx-shortcuts__link--active"),t.isIntersecting&&t.boundingClientRect.top{const e=document.getElementById(t);l.observe(e)}))}attachScrollToArea(t){t.forEach((t=>{t.addEventListener("click",(e=>{e.preventDefault();const n=this.listWrapper.clientHeight+16,i=document.getElementById(t.getAttribute("data-xpr-shortcuts-anchor-target"));b({scrollToElement:i,offset:n}),i&&i.focus()}))}))}}const w=document.querySelectorAll('[data-xpr-component="shortcuts"]');async function _(t,e){if(t){const i=function(t){const e=new ArrayBuffer(t.length),n=new Uint8Array(e);for(let e=0,i=t.length;e{t.shortcutsComponent=new v(t)})),window.Alpine.data("stepper",((t,e,n,i,r)=>({componentId:null,currentCount:null,maxCount:null,enableDelete:null,showDeleteButton:null,decrementBtnDisabled:!1,incrementBtnDisabled:!1,statusMessage:"",statusMessageTimeout:2e3,init(){this.componentId=t,this.currentCount=Number(e||1),this.maxCount=Number(n||9),this.enableDelete=!0===i||"true"===i,this.updateDisabledStates(),window.phoenix.bus.subscribe("STEPPER","UPDATE_QUANTITY",this?.updateQuantity.bind(this))},update(t,e){if("true"!==t.target.getAttribute("aria-disabled")){switch(e){case"decrement":this.decrementBtnDisabled||(this.currentCount&&this.currentCount>1&&(this.currentCount-=1,this.updateStatusMessage()),window.phoenix.bus.publish("STEPPER","DECREMENT",{payload:{componentId:this.componentId,current:this.currentCount,max:this.maxCount}}));break;case"increment":this.incrementBtnDisabled||(this.currentCount&&this.maxCount&&this.currentCount{this.statusMessage=""}),this.statusMessageTimeout)}}))),window.Alpine.data("tabs",(t=>({activeTab:t,nodeRef:{main:document.createElement("div")},tabs:[],tabTitles:[],init(){this.tabs=Array.from(this.$el.querySelectorAll("[role='tab']")),this.nodeRef={main:this.$el},window.phoenix.bus.subscribe("TABS","RENDER_TITLES",this.renderTitles.bind(this)),window.phoenix.bus.subscribe("TABS","SET_ACTIVE_TAB",this.fetchActiveTab.bind(this)),window.phoenix.bus.subscribe("TABS","REMOVE_TAB",this.removeTab.bind(this)),this.$nextTick?.((()=>{this.assignActiveTab(this.activeTab),this.setActiveTabByHash()}))},removeTab(t){const e=t?.payload?.removeTabId;if(e){const t=this.$el?.querySelector('[data-tab-name="'+e+'"]'),n=t?.getAttribute("aria-controls");if(n){const i=this.$el?.querySelector("#"+n);t?.remove(),i?.remove(),this.tabs=Array.from(this.$el.querySelectorAll("[role='tab']")),this.activeTab==e&&this.tabs.length>0&&this.assignActiveTab(this.tabs[0].getAttribute("data-tab-name")??"")}}},assignActiveTab(t){this.activeTab=t;const e=this.$refs?.root,n=this.$refs?.["tab-selector"],i=e?.querySelector(`[data-tab-name="${t}"]`);if(i&&n){const{offsetLeft:t,offsetWidth:e}=i;n.style.left=`${t}px`,n.style.width=`${e}px`}if(this.nodeRef.main.hasAttribute("data-analytics-enable-tracking")){const t={title:this.$el?.getAttribute("data-analytics-title")??"#",isModal:!1};if(this.nodeRef.main.closest("[data-xpr-modal]")){const e=this.nodeRef.main.closest("[data-xpr-modal]");t.isModal=!0,t.modalTitle=e?.getAttribute("data-analytics-component-title")??"#"}window.phoenix.bus?.publish("TABS","CHANGE",{payload:t})}},fetchActiveTab(t){this.assignActiveTab(t?.payload?.activeTabId??"")},onKeydown(t){const e=t.target;let n=!1;if(e)switch(t.key){case"ArrowLeft":this.focusPreviousTab(e),n=!0;break;case"ArrowRight":this.focusNextTab(e),n=!0;break;case"End":this.goToLastTab(),n=!0;break;case"Home":this.goToFirstTab(),n=!0}n&&(t.stopPropagation(),t.preventDefault())},goToLastTab(){this.tabs[this.tabs.length-1].focus()},goToFirstTab(){this.tabs[0].focus()},focusPreviousTab(t){if(this.tabs[0]===t)this.goToLastTab();else{const e=this.tabs.indexOf(t);this.tabs[e-1].focus()}},focusNextTab(t){if(t===this.tabs[this.tabs.length-1])this.goToFirstTab();else{const e=this.tabs.indexOf(t);this.tabs[e+1].focus()}},setActiveTabByHash(){const t=window.location.hash,e=t?.replace("#","");t&&this.assignActiveTab(e)},renderTitles(t){this.tabTitles=t?.payload??[]}})));const A={appName:"phoenix-experience",className:"getErrorMessage"};const E={AMEX:"amex",DATA_ATTRIBUTE_CC_TYPE:"data-cc-type",BLOCKS_CVV_AMEX:[4],BLOCKS_CVV_DEFAULT:[3],EXPECTED_LENGTH_CVV_AMEX:4,EXPECTED_LENGTH_CVV_DEFAULT:3,EXPECTED_LENGTH_CC_AMEX:15,EXPECTED_LENGTH_CC_DEFAULT:16},x={appName:"phoenix-experience",className:"FormValidation"},T=()=>({numericOnly:!0,blocks:E.BLOCKS_CVV_AMEX,onValueChanged:function(){const t=this.element?.getAttribute("data-xpr-field-iodine");if(t)try{const e=JSON.parse(t)?.find((t=>t.includes("tmoCreditCardCvv")))?.split(":")[1],n=document.querySelector(`input[name="${e}"]`),i=n?.getAttribute(E.DATA_ATTRIBUTE_CC_TYPE),r=i===E.AMEX;this.properties.blocks=r?E.BLOCKS_CVV_AMEX:E.BLOCKS_CVV_DEFAULT}catch(t){window.phoenix.log.error("Missing Credit Card input: Credit Card input with cc data type is required for this to work",x)}}});function I(t){if(null==t||""===t)return!1;const e=t.replace(/ /g,"");if(e.startsWith("*"))return!0;let n=e.split("").map(Number);const i=n.pop();n=n.reverse().map(((t,e)=>(e%2==0&&(t*=2)>9&&(t-=9),t)));return 9*n.reduce(((t,e)=>t+e),0)%10===i}function C(t){return t===E.AMEX}function S(t,e){return(e?E.EXPECTED_LENGTH_CC_AMEX:E.EXPECTED_LENGTH_CC_DEFAULT)===t.length}function D(t){const e=t.value.replace(/ /g,""),n=C(t.getAttribute(E.DATA_ATTRIBUTE_CC_TYPE)),i=S(e,n),r=!!i&&I(e);return{isValidLength:i,cardNumberNoSpaces:e,isAmexCardType:n,validLuhnCheck:r,isValid:i&&r}}const L=t=>({creditCard:!0,onValueChanged:function(e){const n=e?.target?.rawValue,i=t[e.target.name],r=i.node.closest("[data-xpr-form-input]"),a=r?.querySelector("[data-cleave-type-aria]"),o=this.properties.creditCardType;r?.setAttribute(E.DATA_ATTRIBUTE_CC_TYPE,o),i.node.setAttribute(E.DATA_ATTRIBUTE_CC_TYPE,o),a?.setAttribute("aria-label",o),(t=>{if(null===t.getAttribute("data-cc-mask")){let e;t.setAttribute("data-cc-mask","true"),t.addEventListener("blur",(()=>{const{cardNumberNoSpaces:n,isAmexCardType:i,isValid:r}=D(t);r&&(e=t.value,t.value=function(t,e){const n=t.replace(/ /g,"").slice(-4);return e?`**** ****** *${n}`:`**** **** **** ${n}`}(n,i))})),t.addEventListener("focusin",(()=>{const{isValid:n}=D(t);n&&(t.value=e)}))}})(i.node),window.phoenix.bus.publish("CLEAVE","CREDIT_CARD",{payload:{cardType:o,value:n,isAmex:C(o)}})}}),F=t=>{t?.value?.length&&(t.value="$"+t.value)},M=t=>({numeral:!0,numeralPositiveOnly:!0,onValueChanged:e=>{const n=t[e.target.name];var i;n.cleave.rawValue=e.target.rawValue,i=n.node,i?.getAttribute("data-xpr-price-mask")||(i?.setAttribute("data-xpr-price-mask","true"),i?.addEventListener("input",F.bind(null,i)),F(i))}}),O=t=>({blocks:[11],onValueChanged:function(e){const n=e?.target?.rawValue;t[e.target.name].cleave.rawValue=n}});function N(t){return t&&t.length>=7&&t.length<=17}const k=t=>({numericOnly:!0,blocks:[17],onValueChanged:function(e){const n=e?.target?.rawValue;(t=>{if(null===t.getAttribute("data-account-mask")){let e;t.setAttribute("data-account-mask","true"),t.addEventListener("focusout",(()=>{N(t.value)&&(e=t.value,t.value=function(t){return t.value?.slice(-4).padStart(t.value.length,"*")}(t))})),t.addEventListener("focusin",(()=>{N(t.value)&&(t.value=e)}))}})(t[e.target.name].node),window.phoenix.bus.publish("CLEAVE","ACCOUNT_NUMBER",{payload:{value:n}})}});function P(t,e){e.forEach((e=>{const n=e.hasAttribute("data-xpr-field-cleave"),i=e.getAttribute("data-xpr-field-cleave"),r=(t=>({date:{date:!0,delimiter:"/",datePattern:["m","d","Y"]},numeral:{numeral:!0,delimiter:"",numeralDecimalScale:0},phone:{numericOnly:!0,blocks:[0,3,3,4],delimiters:["(",") ","-"],onValueChanged:function(e){const n=e?.target,i=n?.rawValue;t[n?.name].cleave.rawValue=i}},"tmo-phone-pin":{numericOnly:!0,blocks:[6],delimiters:[""],onValueChanged:function(e){const n=e?.target,i=n?.rawValue;t[n?.name].cleave.rawValue=i}},ssn:O(t),"cc-number":{creditCard:!0},"cc-expiration":{date:!0,datePattern:["m","y"]},"cc-cvv":{numericOnly:!0,blocks:[4]},"tmo-cc-number":L(t),"tmo-cc-cvv":T(),"tmo-account-number":k(t),"tmo-price":M(t)}))(t)[i],a=function(t){try{t=JSON.parse(t)}catch(t){return!1}return"object"==typeof t&&null!==t}(i);if(n)if(r)new window.Cleave(e,r);else{if(!a)return;new window.Cleave(e,JSON.parse(i))}}))}const V={appName:"phoenix-experience",className:"FormValidation"};class R{inputElements;inputs;isFormStarted;isFormClean;isFormValid;isFormComplete;componentIdSymbol;form;constructor(t,e){this.inputElements=t,this.inputs={},this.isFormStarted=!1,this.isFormClean=!1,this.isFormComplete=!1,this.isFormValid=!1,this.form=e,this.initValidationService()}initValidationService(){[...this.inputElements].forEach((t=>{this.inputs[t.name]={blurred:!1,disabled:!("true"!=t.getAttribute("aria-disabled")&&!t.getAttribute("disabled")),errorMessage:"",node:t,nodeContainer:t.closest("[data-xpr-form-input]"),nodeTrack:t.closest("[data-xpr-form-track]"),nodeError:t.closest("[data-xpr-form-input]")?.querySelector("[data-xpr-field-feedback-error]"),nodeErrorText:t.closest("[data-xpr-form-input]")?.querySelector("[data-xpr-field-feedback-error] span"),cleave:{rawValue:""},messages:{required:t.dataset?.xprFieldErrorRequired??"",requiredChoice:t.dataset?.xprFieldErrorRequired??"",minLength:t.dataset?.xprFieldErrorLengthmin??"",maxLength:t.dataset?.xprFieldErrorLengthmax??"",regexMatch:t.dataset?.xprFieldErrorRegex??""},returnRawValue:!!t.hasAttribute("data-xpr-field-rawvalue")}})),this.validate(),this.setInitialInputStates(),P(this.inputs,this.inputElements)}setInitialInputStates(){[...this.inputElements].forEach((t=>{const e=this.inputs[t.name],n=t.getAttribute("data-xpr-field-value")||"";e?.nodeTrack?.setAttribute("data-complete",t?.value?.length>=1||n.length>=1?"true":"false"),e?.nodeTrack?.setAttribute("data-disabled","true"==t?.getAttribute("aria-disabled")||t?.getAttribute("disabled")?"true":"false")}))}validate(){return this.isFormClean=!0,[...this.inputElements].forEach((t=>{const e=this.inputs[t.name];e.errorMessage=function(t,e){let n;try{n=window.Iodine.is(t.value,JSON.parse(t.getAttribute("data-xpr-field-iodine")??"{}"))}catch(n){return void window.phoenix.log.debug(`${String.fromCodePoint(128683)} form initialization error: "${t.name}" input could not be initialized. Please verify your Iodine configuration is valid.`,A)}const i=e[t.name]?.blurred,r=("string"==typeof n&&e[t.name]?.messages[n?.split(":")[0]])??"";if("checkbox"===t.type&&(t.closest('[role="group"]')||t.closest("fieldset"))&&"true"===t.getAttribute("aria-required")){const e=t.closest('[role="group"]')||t.closest("fieldset"),n=e?.querySelectorAll('input[type="checkbox"]:checked');if(n?.length)return t.required=!1,"";t.required=!0}return!0!==n&&i&&r?r:!0!==n&&i&&"string"==typeof n?window.Iodine.getErrorMessage(n):""}(t,this.inputs)??"",t.checkValidity()&&!e.errorMessage||(this.isFormClean=!1),e.nodeError?.setAttribute("aria-hidden",e.errorMessage?"false":"true"),e.nodeErrorText&&(e.nodeErrorText.textContent=e.errorMessage),e.errorMessage?e.node?.setAttribute("aria-invalid","true"):e.node?.removeAttribute("aria-invalid")})),this.isFormClean}getFormData(){if(this.form)return function(t,e){const n=new FormData(t),i={};return n.forEach(((t,n)=>{Reflect.has(i,n)?(Array.isArray(i[n])||(i[n]=[i[n]]),i[n].push(t)):""!==e[n]?.cleave?.rawValue?i[n]=e[n]?.cleave?.rawValue:i[n]=t})),i}(this.form,this.inputs);window.phoenix.log.error("Missing Argument: Service must be passed a form to use getFormData()",V)}registerForm(t){this.componentIdSymbol=t,window.phoenix.bus.publish("FORM","REGISTER",{id:this.componentIdSymbol})}unregisterForm(){window.phoenix.bus.publish("FORM","UNREGISTER",{id:this.componentIdSymbol})}handleFormChange(t){const e=t.target,n=this.inputs[e?.name];if(this.analyticsFormStart(),n?.nodeTrack?.setAttribute("data-complete",e?.value?.length>=1?"true":"false"),"focusout"===t.type&&((e?.value?.length>1||"focusout"===t.type)&&(n.blurred=!0),this.isFormValid=this.validate(),this.isFormValid&&!this.isFormComplete)){if(this.form){const t=this.form.cloneNode(!0);t.querySelector('input[type="checkbox"]')?.remove(),this.form.querySelector("[data-xpr-lead-gen]")||window.phoenix.bus.publish("FORM","COMPLETE",{payload:{form:{$el:t}}})}this.isFormComplete=!0}}publishFormValidity(t){const e=this.isFormValid?"VALID":"INVALID";window.phoenix.bus.publish("FORM",e,{payload:t,id:this.componentIdSymbol})}resetFormValidation(){this.isFormStarted=!1,this.isFormClean=!1,this.isFormComplete=!1,this.isFormValid=!1,[...this.inputElements].forEach((t=>{const e=this.inputs[t.name];e.blurred=!1,e.errorMessage="",e.cleave.rawValue="",e.nodeError?.setAttribute("aria-hidden","true"),e.node?.removeAttribute("aria-invalid"),e.nodeTrack?.setAttribute("data-complete","false")}))}analyticsFormStart(){!this.isFormStarted&&this.form&&this.form?.hasAttribute("data-analytics-enable-tracking")&&(window.phoenix.bus.publish("FORM","START",{payload:{form:{$el:this.form}}}),this.isFormStarted=!0)}}const $={appName:"phoenix-experience",className:"TPayValidation"};class B{$el;componentId;isFormValid=!1;componentIdSymbol;selectedTPayData;lastValidatedCardNumber;encryptedCard;encryptedCvv;publicKey={};handoffData={};isApplePayAvailable=!1;formInputs;formValidationService;tpayConfigs;tpayForm;isTPayEdit;isEditModified;cardTypeLogo;constructor(t,e,n){this.$el=e,this.componentId=t,this.componentIdSymbol=Symbol(t),this.tpayForm=n}initFormFields(){const t=this.$el.querySelectorAll(`[data-xpr-field*=${this.componentId}]`);return this.formValidationService=new R(t),this.formInputs=this.formValidationService.inputs,this.formInputs}paymentTypeChanged(){"card"===this.selectedTPayData?.selectedPaymentType?this.isFormValid&&(this.selectedTPayData.cardHolderName=this.tpayForm.cardHolderName.value,this.selectedTPayData.cardNumber=this.encryptedCard,this.selectedTPayData.cardType=this.getCardType(this.tpayForm.cardNumber.value),this.selectedTPayData.expirationDate=this.tpayForm.expirationDate.value,this.selectedTPayData.cvv=this.tpayConfigs.isCvvEncryptionEnabled?this.encryptedCvv:this.tpayForm.cvv.value,this.validateForm()):this.setTPayHandOff()}paymentErrorHandling(){return this.tpayForm.cardNumber.value="",this.tpayForm.cvv.value="",this.tpayForm.expirationDate.value="",this.selectedTPayData={...this.selectedTPayData,cardNumber:"",cvv:"",expirationDate:""},this.handoffData={},window.phoenix.bus.publish("FORM","INVALID",{id:this.componentIdSymbol}),this.tpayForm}clearFieldOnEdit(t,e){return"keydown"===t&&"Tab"!=e&&this.isTPayEdit&&!this.isEditModified&&(this.tpayForm.cardNumber.value="",this.tpayForm.cvv.value="",this.formInputs.cardNumber.blurred=!0,this.formInputs.cvv.blurred=!0,this.isEditModified=!0,this.selectedTPayData={...this.selectedTPayData,cardNumber:"",cvv:""},this.handoffData={},window.phoenix.bus.publish("FORM","INVALID",{id:this.componentIdSymbol})),this.tpayForm}async formValueChanged(t,e,n){this.formValidationService?.validate();const i=""===this.formInputs[e].errorMessage;return this.tpayForm=n,this.tpayForm[e].isValid=i,this.tpayForm[e].isTouched=!0,this.isTPayEdit&&!this.isEditModified||i&&("cardHolderName"===e?this.cardHolderNameChanged(t):"cardNumber"===e?this.cardNumberChanged(t):"expirationDate"===e?this.expirationDateChanged(t):"cvv"===e&&await this.cvvChanged(t)),this.tpayForm}validateCvvLength(){const t=this.tpayForm.cardNumber.value?.replace(/\s/g,""),e=this.getCardType(t);this.selectedTPayData={...this.selectedTPayData,cardType:e};const n="Amex"===e?4:3,i=this.formInputs.cvv;i.node?.setAttribute("minlength",n.toString()),i.node?.setAttribute("maxlength",n.toString()),i.node?.setAttribute("cardType",e),this.formValidationService?.validate();const r=this.tpayForm.cvv.isTouched&&""===i.errorMessage;return this.tpayForm.cvv.minLength=n,this.tpayForm.cvv.maxLength=n,this.tpayForm.cvv.isValid=r,this.tpayForm.cvv.errorMessage=r?"":"A valid CVV is required.",r}validateCardNumberLength(t){const e=t.replace(/\s/g,""),n=this.getCardType(e),i="Amex"===n?17:19,r=this.formInputs.cardNumber;r.node?.setAttribute("minlength",i.toString()),r.node?.setAttribute("maxlength",i.toString()),r.node?.setAttribute("cardType",n),this.tpayForm.cardNumber.maxLength=i,this.tpayForm.cardNumber.minLength=i,this.formValidationService?.validate();return this.tpayForm.cardNumber.isTouched&&""===r.errorMessage}cardHolderNameChanged(t){const e=t.target?.value;this.selectedTPayData={...this.selectedTPayData,cardHolderName:e},this.validateForm()}validateFieldLength(t){const e=t.target.name,n=t.target?.value;"cardNumber"===e?this.validateCardNumberLength(n):"cvv"===e&&this.validateCvvLength()}cardNumberChanged(t){const e=t.target?.value,n=e.replace(/\s/g,"");this.validateCardNumberLength(n),this.validateCvvLength(),this.lastValidatedCardNumber!==n?this.getCardTypeValidation(n):this.validateForm()}expirationDateChanged(t){const e=t.target?.value,n=t.target?.name,i=this.tpayConfigs?.invalidExpirationDate,r=this.tpayConfigs?.invalidMaxExpirationDate,a=this.tpayConfigs?.invalidMax20YearsExpirationDate;let o=i,s=!0;const u=parseInt(e.substring(0,2),10),l=parseInt(e.substring(3),10),c=parseInt((new Date).getFullYear().toString().substring(2),10),d=parseInt((new Date).getMonth().toString().substring(0,2),10)+1,h=this.tpayConfigs?.maxExpiryYear,p=window.Iodine.isString(h)&&""!==h,f=p?parseInt(h.substring(2,4)):c+20,m=p?r?.replace("{{years}}",h):a;l===f?ud?(s=!1,o=m):s=!0:l=f?(s=!1,o=m):s=!(u{const e=this.tpayForm[t];this.tpayForm[t].isValid=""===this.tpayForm[t].errorMessage;const n=this.formInputs[t];if(""===this.formInputs[t].errorMessage){const t=e.isTouched&&""!==e.errorMessage;n.nodeError?.setAttribute("aria-hidden",t?"false":"true"),n.nodeErrorText.textContent=t?e.errorMessage:"",n.node?.setAttribute("aria-invalid",t?"true":"false")}}))}checkTouchedAndValid(){const t=Object.values(this.tpayForm),e=t.some((t=>t.isTouched&&""===t.value)),n=t.some((t=>!t.isValid)),i=!e&&!n&&this.formValidationService?.isFormClean;return i||window.phoenix.bus.publish("FORM","INVALID",{id:this.componentIdSymbol}),i}checkIsDataChanged(){const t={cardHolderName:this.tpayForm.cardHolderName.value,cardNumber:this.tpayForm.cardNumber.value,expirationDate:this.tpayForm.expirationDate.value,cvv:this.tpayForm.cvv.value,autoPayDiscountEligible:this.selectedTPayData?.autoPayDiscountEligible};return JSON.stringify(t)!==JSON.stringify(this.handoffData)}validateForm(){this.checkCustomError(),this.isFormValid=this.checkTouchedAndValid(),this.isFormValid&&(this.checkIsDataChanged()?this.createNonce():""!==this.selectedTPayData?.pKitNonce&&this.setTPayHandOff())}validatePKitNonce(){this.checkCustomError();const t=this.checkIsDataChanged()&&""!==this.selectedTPayData?.pKitNonce;this.isFormValid=this.checkTouchedAndValid(),t&&this.isFormValid&&this.setTPayHandOff()}setTPayHandOff(){this.selectedTPayData?.selectedPaymentType||(this.selectedTPayData={...this.selectedTPayData,selectedPaymentType:"card"}),window.phoenix.log.debug(`%c TPAY: HANDOFF font-weight:600;color:#000000;background-color:#55FF55;padding:2px;border-left:5px solid black; ${JSON.parse(JSON.stringify(this.selectedTPayData))}`,$),this.handoffData={cardHolderName:this.tpayForm.cardHolderName.value,cardNumber:this.tpayForm.cardNumber.value,expirationDate:this.tpayForm.expirationDate.value,cvv:this.tpayForm.cvv.value,autoPayDiscountEligible:this.selectedTPayData?.autoPayDiscountEligible},window.localforage.setItem("TPAY_HANDOFF",this.selectedTPayData),window.phoenix.bus.publish("FORM","VALID",{payload:{...this.selectedTPayData},id:this.componentIdSymbol})}}const q={appName:"phoenix-experience",className:"tpayInlineComponent"};window.Alpine.data("tpayInlineComponent",(t=>({componentId:t,componentIdSymbol:Symbol(t),isApplePayAvailable:!1,isAutoPayEnabled:!1,isDisplayAutoPayDiscountTidbit:!1,cardTypeLogo:"cardImage plain-card",selectedTPayData:{},isDisplayError:!1,isFormStarted:!1,isFormComplete:!1,tpayValidation:{},publicKey:{},errorMessage:"",tpayForm:{cardHolderName:{isTouched:!1,isValid:!1,minLength:2,maxLength:40,value:"",errorMessage:"",isValueAtMaxLength:!1},cardNumber:{isTouched:!1,isValid:!1,minLength:16,maxLength:19,value:"",errorMessage:"",isValueAtMaxLength:!1},expirationDate:{isTouched:!1,isValid:!1,minLength:5,maxLength:5,value:"",errorMessage:"",isValueAtMaxLength:!1},cvv:{isTouched:!1,isValid:!1,minLength:3,maxLength:3,value:"",errorMessage:"",isValueAtMaxLength:!1}},async init(){this.tpayValidation=new B(this.componentId,this.$el,this.tpayForm),window.phoenix.experience?.utils?.FormAutofill&&(this.tpayFormAutofill=new window.phoenix.experience.utils.FormAutofill),this.formInputs=this.tpayValidation.initFormFields(),this.initEvents(),await this.checkEditFlow(),this.checkPaymentError()},initEvents(){this.setTPayConfigsAndInit(),window.phoenix.bus.subscribe("TPAY","PUBLIC_KEY",this.setPublicKey.bind(this)),window.phoenix.bus.subscribe("TPAY","APPLEPAY_ELIGIBILITY",this.setApplePayEligibility.bind(this)),window.phoenix.bus.subscribe("TPAY","NONCE_TOKEN",this.setNonceToken.bind(this)),window.phoenix.bus.subscribe("TPAY","GET_AUTOPAY_DISCOUNT_ELIGIBILITY_SUCCESS",this.setAutoPayDiscountEligibility.bind(this)),window.phoenix.bus.subscribe("TPAY","CARD_TYPE",this.setCardType.bind(this)),window.phoenix.bus.publish("FORM","REGISTER",{id:this.componentIdSymbol}),window.phoenix.bus.subscribe("FORM_AUTOFILL","COMPLETE",this.setAutofill.bind(this))},async setAutofill(t){const e=t.payload,n=e?.target;n&&n.name&&(""===n.value?this.clearAutofill():("cvv"===n.name&&n.focus(),await this.change(e)))},clearAutofill(){this.tpayValidation.handoffData={},this.tpayValidation.lastValidatedCardNumber="",this.selectedTPayData={},this.selectedTPayData={...this.selectedTPayData,cardNumber:"",cvv:"",expirationDate:""},this.tpayValidation.selectedTPayData=this.selectedTPayData,this.tpayValidation.validateForm(),window.phoenix.bus.publish("FORM","INVALID",{id:this.componentIdSymbol})},setTPayConfigsAndInit(){this.tpayConfigs=window.phoenix.configs.tpayConfigs,this.tpayValidation.tpayConfigs=window.phoenix.configs.tpayConfigs,window.phoenix.bus.publish("TPAY","INIT",{}),(this.tpayConfigs.isCardHolderNameDisabled||this.tpayConfigs.isAutopayEligibilityToggleEnabled)&&window.phoenix.bus?.subscribe("CART","FETCHED_CART_SUCCESS",this.setCartData.bind(this))},setPublicKey(t){t.payload&&(this.publicKey=t.payload,this.tpayValidation.publicKey=t.payload)},setApplePayEligibility(t){const e=t.payload?.isApplePayAvailable||!1;this.isApplePayAvailable=e,this.tpayValidation.isApplePayAvailable=e},setCartData(t){if(!this.tpayForm.cardHolderName.value&&this.tpayConfigs?.isCardHolderNameDisabled){const e=t.payload?.billing?.firstName,n=t.payload?.billing?.lastName?" "+t.payload.billing?.lastName:"";this.tpayForm.cardHolderName.value=e+n}""!==this.tpayForm.cardHolderName.value?(this.tpayForm.cardHolderName.isTouched=!0,this.tpayForm.cardHolderName.isValid=!0):(this.tpayForm.cardHolderName.isTouched=!1,this.tpayForm.cardHolderName.isValid=!1),this.tpayValidation.tpayForm=this.tpayForm,this.isAutoPayEnabled=Boolean(t.payload?.autoPay),this.validateAutoPayEligibility()},async setCardType(t){if(this.tpayForm.cardNumber.errorMessage=t.payload?.isCardValid?"":this.tpayValidation.tpayConfigs?.invalidCardNumber,this.tpayForm.cardNumber.isValid=t.payload?.isCardValid,t.payload?.isCardValid){const t=this.tpayForm.cardNumber.value?.replace(/\s/g,"")||"",e=await _(this.publicKey,t);this.tpayValidation.lastValidatedCardNumber=t,this.tpayValidation.encryptedCard=e,this.tpayValidation.selectedTPayData={...this.tpayValidation.selectedTPayData,cardNumber:e},this.validateAutoPayEligibility()}this.tpayValidation.tpayForm=this.tpayForm,this.tpayValidation.validateForm()},validateAutoPayEligibility(){this.tpayConfigs?.isAutopayEligibilityToggleEnabled&&this.isAutoPayEnabled&&Boolean(this.tpayValidation?.selectedTPayData?.cardNumber)?this.getAutoPayDiscountEligibility(this.tpayValidation.selectedTPayData?.cardNumber):(this.isDisplayAutoPayDiscountTidbit=!1,this.tpayValidation.selectedTPayData={...this.tpayValidation.selectedTPayData,autoPayDiscountEligible:"OFF"},this.tpayValidation.tpayForm=this.tpayForm,this.tpayValidation.validateForm())},getAutoPayDiscountEligibility(t){window.phoenix.bus.publish("TPAY","GET_AUTOPAY_DISCOUNT_ELIGIBILITY",{payload:{encryptedCardNumber:t}})},setAutoPayDiscountEligibility(t){const e=t?.payload,n=e.isError?"ERROR":e.isAutoPayDiscountEligible?"ELIGIBLE":"INELIGIBLE";this.isDisplayAutoPayDiscountTidbit="INELIGIBLE"===n,this.tpayValidation.selectedTPayData={...this.tpayValidation.selectedTPayData,autoPayDiscountEligible:n},this.tpayValidation.tpayForm=this.tpayForm,this.tpayValidation.validateForm()},setNonceToken(t){if(void 0===t.payload?.nonceToken){const t={payload:{error:"Error",message:this.tpayValidation.tpayConfigs?.invalidCardNumber,form:{$el:this.$root}}};window.phoenix.bus?.publish("FORM","ERROR",t)}const e=t.payload?.isError?"":t.payload?.nonceToken,n=void 0!==e;this.tpayForm.cardNumber.errorMessage=n?"":this.tpayValidation.tpayConfigs?.invalidCardNumber,this.tpayForm.cardNumber.isValid=n,this.selectedTPayData={...this.tpayValidation.selectedTPayData,pKitNonce:e},this.tpayValidation.selectedTPayData={...this.tpayValidation.selectedTPayData,pKitNonce:e},this.tpayValidation.tpayForm=this.tpayForm,this.tpayValidation.validatePKitNonce(),this.isDisplayError=this.isDisplayError&&""===e},paymentTypeChanged(t){const e=t.target;this.selectedTPayData={},this.selectedTPayData={...this.selectedTPayData,selectedPaymentType:e.dataset?.xprFieldSelectedType},this.tpayValidation.selectedTPayData=this.selectedTPayData,this.tpayValidation.paymentTypeChanged()},keyDown(t){this.tpayForm=this.tpayValidation.clearFieldOnEdit(t.type,t.key)},async keyUp(t){if(this.tpayValidation.getCardType(this.tpayForm.cardNumber.value),this.cardTypeLogo=this.tpayValidation.cardTypeLogo,"Tab"===t.key)return;const e=t.target,n=e.name,i=this.tpayForm[n];i&&(e.maxLength===e.value.length?(i.isValueAtMaxLength=!0,this.tpayForm=await this.tpayValidation.formValueChanged(t,n,this.tpayForm)):(i.isValid=!1,i.isValueAtMaxLength=!1,this.tpayValidation.tpayForm=this.tpayForm,this.tpayValidation.formValidationService?.validate(),window.phoenix.bus.publish("FORM","INVALID",{id:this.componentIdSymbol})))},async change(t){const e=t.target.name,n=this.formInputs[e],i=this.tpayValidation.getCardType(this.tpayForm.cardNumber.value);n&&("keydown"===t.type&&"Tab"==t.key||(""!==i&&this.tpayValidation.validateFieldLength(t),"focusout"!==t.type&&"autofill"!==t.type||(n.blurred=!0,this.tpayForm=await this.tpayValidation.formValueChanged(t,e,this.tpayForm)),this.isFormStarted||this.formStart.call(this),this.tpayValidation.checkTouchedAndValid()&&!this.isFormComplete&&(this.isFormComplete=!0,window.phoenix.bus.publish("FORM","COMPLETE",{payload:{form:{$el:this.$root}}}))))},async checkEditFlow(){try{const t=await window.localforage.getItem("TPAY_HANDOFF");t?(this.tpayValidation.isTPayEdit=!0,this.setEditFieldValues(t),window.phoenix.bus.publish("FORM","VALID",{payload:{...this.selectedTPayData},id:this.componentIdSymbol})):window.phoenix.bus.publish("FORM","INVALID",{id:this.componentIdSymbol})}catch(t){window.phoenix.log.debug(t instanceof Error?t.message:"",q,{exception:t})}},checkPaymentError(){const t=new URL(window.location.href).searchParams.get("error");if(null!==t){const e=t.toLowerCase();"harddecline"===e?(this.errorMessage=this.tpayValidation.tpayConfigs?.hardDeclineError,this.setAndPubishPaymentError()):"softdecline"===e?(this.errorMessage=this.tpayValidation.tpayConfigs?.softDeclineError,this.setAndPubishPaymentError()):"default"===e&&(this.errorMessage=this.tpayValidation.tpayConfigs?.defaultPaymentError,this.setAndPubishPaymentError())}},setAndPubishPaymentError(){this.tpayForm=this.tpayValidation.paymentErrorHandling(),this.isDisplayError=!0;const t={payload:{error:"Error",message:this.errorMessage,form:{$el:this.$root}}};window.phoenix.bus?.publish("FORM","ERROR",t)},setEditFieldValues(t){this.tpayForm.cardHolderName.value=t.cardHolderName,this.tpayForm.expirationDate.value=t.expirationDate;const e=new URL(window.location.href).searchParams.get("error");"harddecline"===e?.toLowerCase()||"softdecline"===e?.toLowerCase()?this.cardTypeLogo="cardImage plain-card":this.cardTypeLogo="cardImage "+(""===t.cardType?"plain-card":t.cardType),"Amex"===t.cardType?(this.tpayForm.cardNumber.value="**** ****** *"+t.pKitNonce?.substring(t.pKitNonce.length-4),this.tpayForm.cvv.value="****"):(this.tpayForm.cardNumber.value="**** **** **** "+t.pKitNonce?.substring(t.pKitNonce.length-4),this.tpayForm.cvv.value="***"),Object.values(this.tpayForm).forEach((t=>{t.isTouched=!0,t.isValid=!0})),this.isDisplayAutoPayDiscountTidbit=this.tpayConfigs?.isAutopayEligibilityToggleEnabled&&"INELIGIBLE"===t.autoPayDiscountEligible,this.tpayValidation.tpayForm=this.tpayForm,this.tpayValidation.selectedTPayData=t},formStart(){this.isFormStarted=!0,window.phoenix.bus.publish("FORM","START",{payload:{form:{$el:this.$root}}})}}))),window.Alpine.data("video",(()=>({isPlaying:!1,renderButton:!0,player:{},playerRefs:{type:"",title:"",id:"",source:"",youtube:{timeStamp:"",disableSuggestedVideo:""},dynamicMedia:{containerId:"",params:{asset:"",caption:"",serverUrl:"",videoServerUrl:""}}},isMobile:!1,isDynamicMediaVideo:!1,hasDynamicMediaScriptLoaded:!1,init(){this.player=this.$el?.querySelector("[data-xpr-video]");const{playerReferences:t,isDynamicMediaVideo:e}=y(this.player);this.playerRefs=t,this.isDynamicMediaVideo=e,window.phoenix.bus.subscribe("MODAL","HIDE",(()=>{this.isPlaying=!1})),this.$nextTick?.((()=>{this.isDynamicMediaVideo&&(this.hasDynamicMediaScriptLoaded=m(this.player),window.phoenix.bus.subscribe("VIDEO","DYNAMIC_MEDIA_PLAYER_INITIALIZED",this.dynamicMediaPlayerInitialized.bind(this))),this.isDynamicMediaVideo||(window.phoenix.bus.subscribe("MODAL","SHOW",this.startModalVideo.bind(this)),window.phoenix.bus.subscribe("MODAL","HIDE",this.stopModalVideo.bind(this))),this.checkScreenSize()}))},checkScreenSize(){window.phoenix.experience.utils?.registerMediaQuerySensor?.({max:u,action:t=>this.isMobile=t}),this.isMobile&&"youtube"===this.playerRefs.type&&(this.renderButton=!1)},async loadVideo(){this.player&&(this.isDynamicMediaVideo||(await p(this.player,this.playerRefs),this.isPlaying=!0),this.isDynamicMediaVideo&&this.hasDynamicMediaScriptLoaded&&(f(this.playerRefs.dynamicMedia,this.player),this.isPlaying=!0))},startModalVideo(){this.$el&&((t,e,n)=>{const i=t.querySelectorAll("[data-xpr-modal] [data-xpr-video]");let r,a,o;n&&"vimeo"===e.type&&i.forEach((t=>{r=t.getAttribute("data-xpr-video-id"),a=`https://player.vimeo.com/video/${r}?autoplay=1&loop=0&autopause=0`,o=t.querySelector("iframe"),o&&o.setAttribute("src",a)}))})(this.$el,this.playerRefs,this.isPlaying)},stopModalVideo(){this.$el&&((t,e)=>{const n=t.querySelectorAll("[data-xpr-modal] [data-xpr-video]");if(n){let t;switch(n.forEach((t=>{const e=t.querySelector("video");e&&e.pause()})),e.type){case"youtube":n.forEach((e=>{t=e.querySelector("iframe"),t&&t.contentWindow?.postMessage('{"event":"command","func":"stopVideo","args":""}',"*")}));break;case"vimeo":n.forEach((e=>{t=e.querySelector("iframe"),t&&t.setAttribute("src","")}))}}})(this.$el,this.playerRefs)},dynamicMediaPlayerInitialized(t){this.$nextTick?.((()=>{if(t?.payload?.playerId===this.player?.id){const t=this.player?.querySelector(".s7playpausebutton");this.$focus?.focus(t)}}))}})));class j{wrapperElement;constructor(t){this.wrapperElement=t,this.attachVideoControl()}attachVideoControl(){const t=this.wrapperElement.querySelector("button[data-wrapper-video-controls]"),e=this.wrapperElement.querySelector(`[id='${t?.getAttribute("aria-controls")}']`);t&&e&&t.addEventListener("click",this.toggleVideo(e,t))}toggleVideo(t,e){return async()=>{t.paused?(await t.play(),e.ariaPressed="false"):(t.pause(),e.ariaPressed="true")}}}const U=document.querySelectorAll('[data-xpr-component="wrapper"][data-xpr-component-version="1"]');null!==U&&U.forEach((t=>{const e=t;e.wrapperComponent=new j(e)}))}()}();